package com.hgkj.cloud.base.scheme;

import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Comparator;
import java.util.Date;
import java.util.HashMap;
import java.util.Iterator;
import java.util.List;
import java.util.Map;
import java.util.Set;
import java.util.TreeMap;
import java.util.regex.Pattern;

import com.hgkj.cloud.base.common.AdminCommon;
import com.hgkj.cloud.base.domain.EUser;
import com.hgkj.cloud.base.domain.SysTableContent;
import com.hgkj.cloud.base.domain.SysTableDiagnosis;
import com.hgkj.cloud.base.domain.TenantTableTaskInfo;
import com.hgkj.cloud.base.scheme.table.*;
import com.hgkj.cloud.base.service.SysTableBriefService;
import com.hgkj.cloud.base.service.SysTableContentService;
import com.hgkj.cloud.base.service.SysTableDiagnosisService;
import com.hgkj.cloud.base.util.DateTimeUtil;

import net.sf.json.JSONObject;

/**
 * 量表测评报告生成
 */
public class ClsReport {

	private ClsReportResult g_ReportResult = new ClsReportResult();

	private String red_Asterisk = "<label style='color: Red'>*</label>";

	private String sSize = "13";
	private int tWidth = 90;
	private String m_Line = "<hr align='center' width='100%'>"; // 一条中线

	// 1中文或2英文
	private int g_CorE = 1;
	private Boolean g_inblFactor = true; // 是否显示“因子得分”
	private int oWidth = 45; // 60

	private String oSpace = "　";
	private String tSpace = "　　";

	private SysTableBriefService tableService;
	SysTableContentService sysTableContentService;
	SysTableDiagnosisService mSysTableDiagnosisService;

	public void setTableService(SysTableBriefService service, SysTableContentService mSysTableContentService,
			SysTableDiagnosisService sysTableDiagnosisService) {
		tableService = service;
		sysTableContentService = mSysTableContentService;
		mSysTableDiagnosisService = sysTableDiagnosisService;
	}

	// 调用计算过程
	public ClsReportResult getReports(TenantTableTaskInfo info, EUser user, String factorJson) {
		String strReportSimple = "";
		// String strReportNormal = "";
		String strReportComplete = "";
		String strframework_name = "";
		String strTableName = "";
		String strUserInfo = "";
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		String[] strTableInfo = { "", "", "", "", "" };
		// 量表图片
		String strTableImage = "";

		// 重点提示
		String strTableImportantPrompt = "";
		// 量表指导意见
		String strManagerIdea = "";
		String strReportEnd = "";

		// 年龄
		float floAge;
		String tenantType = "school";
		if (user.getUser_gender() == null)
			user.setUser_gender(1);
		if (user.getUser_birth() != null)
			floAge = DateTimeUtil.getFloatAgeByBirthday(user.getUser_birth());
		else {

			switch (tenantType) {
			case "school":
				floAge = AdminCommon.DEFAULT_SCHOOL_AGE;
				break;
			case "college":
				floAge = AdminCommon.DEFAULT_COLLEGE_AGE;
				break;
			case "fire_fighting":
				floAge = AdminCommon.DEFAULT_FIRE_FIGHTING_AGE;
				break;
			case "prison":
				floAge = AdminCommon.DEFAULT_PRISON_AGE;
				break;
			case "drug_controll":
				floAge = AdminCommon.DEFAULT_DRUG_CONTROLL_AGE;
				break;
			case "police":
				floAge = AdminCommon.DEFAULT_POLICE_AGE;
				break;
			default:
				floAge = 20f;
				break;
			}
		}

		// 单位名称
		strframework_name = GetTableTitleReport("");
		// 量表名称
		strTableName = GetTableTitleReport(info.getChinese_name());
		// 用户基本信息
		strUserInfo = UserInfo(info, user);

		JSONObject jsonObject = JSONObject.fromObject(factorJson);
		@SuppressWarnings("unchecked")
		Map<String, Object> map = (Map<String, Object>) jsonObject;
		// 量表内容信息
		switch (info.getEnglish_name()) {
		case "Rw":
			strTableInfo = new Table1().report(map);
			break;
		case "Rwgj":
			strTableInfo = new Table2().report(map);
			break;
		case "Group":
			strTableInfo = new Table3().report(map);
			break;
		case "Pf16":
			strTableInfo = new Table4().report(map);
			strTableImage = ClsGraph.InsertImage(info.getEnglish_name(), info.getChinese_name(), map);
			break;
		case "Mmpi399":
		case "Mmpi566":
			strTableInfo = new Table5().report(map);
			strTableImportantPrompt = getTableImportantPrompt(info.getEnglish_name(), info.getTable_uuid(),
					info.getAnswer(), user.getUser_gender(), map);
			strTableImage = ClsGraph.InsertImage(info.getEnglish_name(), info.getChinese_name(), map);
			break;
		case "Epq":
			strTableInfo = new Table7().report(map);
			strTableImage = ClsGraph.InsertImage(info.getEnglish_name(), info.getChinese_name(), map);
			break;
		case "Xepq":
			strTableInfo = GetXepqReport(map);
			strTableImage = ClsGraph.InsertImage(info.getEnglish_name(), info.getChinese_name(), map);
			break;
		case "Epps":
			strTableInfo = GetEppsReport(map);
			strTableImage = ClsGraph.InsertImage(info.getEnglish_name(), info.getChinese_name(), map);
			break;
		case "Qizhi":
			strTableInfo = GetQizhiReport(map);
			break;
		case "Phi":
			strTableInfo = GetPhiReport(map);
			break;
		case "Scl90":
			strTableInfo = GetScl90Report(map, floAge, tenantType);
			strTableImportantPrompt = getTableImportantPrompt(info.getEnglish_name(), info.getTable_uuid(),
					info.getAnswer(), user.getUser_gender(), map);
			strTableImage = ClsGraph.InsertImage(info.getEnglish_name(), info.getChinese_name(), map);
			break;
		case "Upi":
			strTableInfo = GetUpiReport(map, info.getTable_uuid(), info.getAnswer());
			break;
		case "Ghq":
			strTableInfo = GetGhqReport(map);
			break;
		case "Cmi":
			strTableInfo = GetCmiReport(map, user.getUser_gender());
			break;
		case "Sds":
			strTableInfo = GetSdsReport(map);
			strTableImportantPrompt = getTableImportantPrompt(info.getEnglish_name(), info.getTable_uuid(),
					info.getAnswer(), user.getUser_gender(), map);
			break;
		case "Hamd":
			strTableInfo = GetHamdReport(map);
			break;
		case "Bdi":
			strTableInfo = GetBdiReport(map);
			strTableImportantPrompt = getTableImportantPrompt(info.getEnglish_name(), info.getTable_uuid(),
					info.getAnswer(), user.getUser_gender(), map);
			break;
		case "Ces":
			strTableInfo = GetCesReport(map);
			strTableImportantPrompt = getTableImportantPrompt(info.getEnglish_name(), info.getTable_uuid(),
					info.getAnswer(), user.getUser_gender(), map);
			break;
		case "Ndi":
			strTableInfo = GetNdiReport(map);
			strTableImportantPrompt = getTableImportantPrompt(info.getEnglish_name(), info.getTable_uuid(),
					info.getAnswer(), user.getUser_gender(), map);
			break;
		case "Sas":
			strTableInfo = GetSasReport(map);
			strTableImportantPrompt = getTableImportantPrompt(info.getEnglish_name(), info.getTable_uuid(),
					info.getAnswer(), user.getUser_gender(), map);
			break;
		case "Stai1":
			strTableInfo = GetStai1Report(map);
			break;
		case "Stai2":
			strTableInfo = GetStai2Report(map);
			break;
		case "Hama":
			strTableInfo = GetHamaReport(map);
			strTableImportantPrompt = getTableImportantPrompt(info.getEnglish_name(), info.getTable_uuid(),
					info.getAnswer(), user.getUser_gender(), map);
			break;
		case "Bai":
			strTableInfo = GetBaiReport(map);
			strTableImportantPrompt = getTableImportantPrompt(info.getEnglish_name(), info.getTable_uuid(),
					info.getAnswer(), user.getUser_gender(), map);
			break;
		case "Lsas":
			strTableInfo = GetLsasReport(map);
			break;
		case "Fne":
			strTableInfo = GetFneReport(map);
			break;
		case "Ask":
			strTableInfo = GetAskReport(map);
			break;
		case "Sad":
			strTableInfo = GetSadReport(map);
			strTableImportantPrompt = getTableImportantPrompt(info.getEnglish_name(), info.getTable_uuid(),
					info.getAnswer(), user.getUser_gender(), map);
			break;
		case "Esli":
			strTableInfo = GetEsliReport(map);
			break;
		case "Hads":
			strTableInfo = GetHadsReport(map);
			break;
		case "Cprs":
			strTableInfo = GetCprsReport(map);
			strTableImportantPrompt = getTableImportantPrompt(info.getEnglish_name(), info.getTable_uuid(),
					info.getAnswer(), user.getUser_gender(), map);
			break;
		case "Bprs":
			strTableInfo = GetBprsReport(map);
			strTableImportantPrompt = getTableImportantPrompt(info.getEnglish_name(), info.getTable_uuid(),
					info.getAnswer(), user.getUser_gender(), map);
			break;
		case "Brms":
			strTableInfo = GetBrmsReport(map);
			strTableImportantPrompt = getTableImportantPrompt(info.getEnglish_name(), info.getTable_uuid(),
					info.getAnswer(), user.getUser_gender(), map);
			break;
		case "Sans":
			strTableInfo = GetSansReport(map);
			break;
		case "Saps":
			strTableInfo = GetSapsReport(map);
			break;
		case "Tess":
			strTableInfo = GetTessReport(map);
			strTableImportantPrompt = getTableImportantPrompt(info.getEnglish_name(), info.getTable_uuid(),
					info.getAnswer(), user.getUser_gender(), map);
			break;
		case "Sers":
			strTableInfo = GetSersReport(map);
			break;
		case "Reses":
			strTableInfo = GetResesReport(map);
			strTableImportantPrompt = getTableImportantPrompt(info.getEnglish_name(), info.getTable_uuid(),
					info.getAnswer(), user.getUser_gender(), map);
			break;
		case "Adl":
			strTableInfo = GetAdlReport(map);
			strTableImportantPrompt = getTableImportantPrompt(info.getEnglish_name(), info.getTable_uuid(),
					info.getAnswer(), user.getUser_gender(), map);
			break;
		case "Sdss":
			strTableInfo = GetSdssReport(map);
			break;
		case "YaleBrown":
			strTableInfo = GetYaleBrownReport(map);
			break;
		case "Nosie":
			strTableInfo = GetNosieReport(map);
			break;
		case "Mast":
			strTableInfo = GetMastReport(map);
			break;
		case "Scap":
			strTableInfo = GetScapReport(map);
			strTableImportantPrompt = getTableImportantPrompt(info.getEnglish_name(), info.getTable_uuid(),
					info.getAnswer(), user.getUser_gender(), map);
			break;
		case "Gds":
			strTableInfo = GetGdsReport(map);
			break;
		case "Bssd":
			strTableInfo = GetBssdReport(map);
			break;
		case "His":
			strTableInfo = GetHisReport(map);
			break;
		case "Hds":
			strTableInfo = GetHdsReport(map);
			break;
		case "Mmse":
			strTableInfo = GetMmseReport(map);
			break;
		case "Cbcl":
			strTableInfo = GetCbclReport(map, user.getUser_gender(), floAge);
			break;
		case "Conn":
			strTableInfo = GetConnReport(map, user.getUser_gender(), floAge);
			break;
		case "Pei":
			strTableInfo = GetPeiReport(map);
			break;
		case "A":
			strTableInfo = GetAReport(map);
			break;
		case "Fs14":
			strTableInfo = GetFs14Report(map);
			break;
		case "Psqi":
			strTableInfo = GetPsqiReport(map);
			break;
		case "Ucla":
			strTableInfo = GetUclaReport(map);
			break;
		case "Asssm":
			strTableInfo = GetAsssmReport(map);
			break;
		case "Dsq":
			strTableInfo = GetDsqReport(map);
			break;
		case "Yffs":
			strTableInfo = GetYffsReport(map);
			break;
		case "Les":
			strTableInfo = GetLesReport(map);
			break;
		case "Issi":
			strTableInfo = GetIssiReport(map, info.getTable_uuid(), info.getAnswer());
			break;
		case "Jyyd":
			strTableInfo = GetJyydReport(map);
			break;
		case "Fes":
			strTableInfo = GetFesReport(map);
			break;
		case "Olson":
			strTableInfo = GetOlsonReport(map, user.getUser_gender());
			break;
		case "Lsr":
			strTableInfo = GetLsrReport(map);
			break;
		case "Lsia":
			strTableInfo = GetLsiaReport(map);
			break;
		case "Lsib":
			strTableInfo = GetLsibReport(map);
			break;
		case "Motion":
			strTableInfo = GetMotionReport(map);
			break;
		case "Gwb":
			strTableInfo = GetGwbReport(map);
			break;
		case "Sf36":
			strTableInfo = GetSf36Report(map);
			break;
		case "Ed":
			strTableInfo = GetEdReport(map);
			break;
		case "Spdall":
			strTableInfo = GetSpdallReport(map);
			break;
		case "Spdm":
			strTableInfo = GetSpdmReport(map);
			break;
		case "Spdf":
			strTableInfo = GetSpdfReport(map);
			break;
		case "Whoqol":
			strTableInfo = GetWhoqolReport(map, info.getAnswer());
			break;
		case "Munsh":
			strTableInfo = GetMunshReport(map);
			break;
		case "Connts":
			strTableInfo = GetConntsReport(map);
			break;
		case "Connt":
			strTableInfo = GetConntReport(map, user.getUser_gender(), floAge);
			break;
		case "Abc":
			strTableInfo = GetAbcReport(map);
			break;
		case "Cars":
			strTableInfo = GetCarsReport(map);
			break;
		case "Embu":
			strTableInfo = GetEmbuReport(map);
			break;
		case "Aslec":
			strTableInfo = GetAslecReport(map);
			break;
		case "Zyqx":
			strTableInfo = GetZyqxReport(map);
			break;
		case "Hldzyqx":
			strTableInfo = GetHldzyqxReport(map);
			break;
		case "Adhd":
			strTableInfo = GetAdhdReport(map);
			break;
		case "Srss":
			strTableInfo = GetSrssReport(map);
			break;
		case "Cgi":
			strTableInfo = GetCgiReport(map);
			break;
		case "Nyls":
			strTableInfo = GetNylsReport(map, user.getUser_gender(), floAge);
			break;
		case "Rutterp":
			strTableInfo = GetRutterpReport(map);
			break;
		case "Ruttert":
			strTableInfo = GetRuttertReport(map);
			break;
		case "Piersharris":
			strTableInfo = GetPiersharrisReport(map);
			break;
		case "Etgj":
			strTableInfo = GetEtgjReport(map);
			break;
		case "Csd":
			strTableInfo = GetCsdReport(map);
			break;
		case "Sasc":
			strTableInfo = GetSascReport(map);
			break;
		case "Dis":
			strTableInfo = GetDisReport(map);
			break;
		case "Qsa":
			strTableInfo = GetQsaReport(map);
			break;
		case "Psai":
			strTableInfo = GetPsaiReport(map);
			break;
		case "Cts48m":
			strTableInfo = GetCts48mReport(map);
			break;
		case "Cts13y":
			strTableInfo = GetCts13yReport(map, user.getUser_gender());
			break;
		case "Cbcl2to3":
			strTableInfo = GetCbcl2to3Report(map, info.getAnswer());
			break;
		case "Sarasontas":
			strTableInfo = GetSarasontasReport(map);
			break;
		case "Sm":
			strTableInfo = GetSmReport(map);
			break;
		case "Xxza":
			strTableInfo = GetXxzaReport(map);
			break;
		case "Xljk":
			strTableInfo = GetXljkReport(map);
			break;
		case "Baby20":
			strTableInfo = GetBaby20Report(map);
			break;
		case "Genius1":
			strTableInfo = GetGenius1Report(map);
			break;
		case "Genius2":
			strTableInfo = GetGenius2Report(map);
			break;
		case "Create":
			strTableInfo = GetCreateReport(map);
			break;
		case "Xxff":
			strTableInfo = GetXxffReport(map);
			break;
		case "Xxdj":
			strTableInfo = GetXxdjReport(map);
			break;
		case "Yzldc":
			strTableInfo = GetYzldcReport(map);
			break;
		case "Ksxwkl":
			strTableInfo = GetKsxwklReport(map);
			break;
		case "Zbxl":
			strTableInfo = GetZbxlReport(map);
			break;
		case "Zxsynl":
			strTableInfo = GetZxsynlReport(map);
			break;
		case "Rjjwnl":
			strTableInfo = GetRjjwnlReport(map);
			break;
		case "Txgxkr":
			strTableInfo = GetTxgxkrReport(map);
			break;
		case "Ssgxkr":
			strTableInfo = GetSsgxkrReport(map);
			break;
		case "Ybzwxng":
			strTableInfo = GetYbzwxngReport(map);
			break;
		case "Gat":
			strTableInfo = GetGatReport(map);
			break;
		case "Xxxljkzh":
			strTableInfo = GetXxxljkzhReport(map);
			break;
		case "Zxxljkzh":
			strTableInfo = GetZxxljkzhReport(map);
			break;
		case "Rc":
			strTableInfo = GetRcReport(map);
			break;
		case "Trauma":
			strTableInfo = GetTraumaReport(map);
			break;
		case "Shcrisis":
			strTableInfo = GetShcrisisReport(map);
			break;
		case "Shirritant":
			strTableInfo = GetShirritantReport(map, info.getAnswer());
			break;
		case "Ppvt":
			strTableInfo = new Table132().report(map);
			break;
		case "Cancer":
			// strTableInfo = GetCancerReport(map, user.getUser_gender());
			map.put("gender", user.getUser_gender());
			strTableInfo = new Table133().report(map);
			break;
		default:

			break;
		}

		// 量表指导意见
		switch (info.getEnglish_name()) {
		case "Upi":
		case "Issi":
		case "Zyqx":
			strManagerIdea = strTableInfo[2];
			break;
		default:
			strManagerIdea = MultiCodeToManagerIdea(strTableInfo[2]);
			break;
		}

		// 报告结尾
		strReportEnd = GetTableEndingReport("管理员");

		strReportSimple = strframework_name + strTableName + m_Line + strUserInfo + m_Line + strTableInfo[1] + m_Line
				+ strReportEnd;
		if (strManagerIdea.equals("失败") || strManagerIdea.equals("")) {
			// strReportNormal = strframework_name + strTableName + m_Line + strUserInfo +
			// m_Line + strTableInfo[1] + m_Line + strReportEnd;
			if (strTableImportantPrompt.equals("失败") || strTableImportantPrompt.equals("")) {
				if (strTableImage.equals("")) {
					strReportComplete = strframework_name + strTableName + m_Line + strUserInfo + m_Line
							+ strTableInfo[1] + m_Line + strReportEnd;
				} else {
					strReportComplete = strframework_name + strTableName + m_Line + strUserInfo + m_Line
							+ strTableInfo[1] + m_Line + strTableImage + m_Line + strReportEnd;
				}
			} else {
				if (strTableImage.equals("")) {
					strReportComplete = strframework_name + strTableName + m_Line + strUserInfo + m_Line
							+ strTableInfo[1] + m_Line + strTableImportantPrompt + m_Line + strReportEnd;

				} else {
					strReportComplete = strframework_name + strTableName + m_Line + strUserInfo + m_Line
							+ strTableInfo[1] + m_Line + strTableImage + m_Line + strTableImportantPrompt + m_Line
							+ strReportEnd;
				}
			}
		} else {
			// strReportNormal = strframework_name + strTableName + m_Line + strUserInfo +
			// m_Line + strTableInfo[1] + m_Line + strManagerIdea + m_Line + strReportEnd;
			if (strTableImportantPrompt.equals("失败") || strTableImportantPrompt.equals("")) {
				if (strTableImage.equals("")) {
					strReportComplete = strframework_name + strTableName + m_Line + strUserInfo + m_Line
							+ strTableInfo[1] + m_Line + strManagerIdea + m_Line + strReportEnd;
				} else {
					strReportComplete = strframework_name + strTableName + m_Line + strUserInfo + m_Line
							+ strTableInfo[1] + m_Line + strTableImage + m_Line + strManagerIdea + m_Line
							+ strReportEnd;
				}
			} else {
				if (strTableImage.equals("")) {
					strReportComplete = strframework_name + strTableName + m_Line + strUserInfo + m_Line
							+ strTableInfo[1] + m_Line + strTableImportantPrompt + m_Line + strManagerIdea + m_Line
							+ strReportEnd;
				} else {
					strReportComplete = strframework_name + strTableName + m_Line + strUserInfo + m_Line
							+ strTableInfo[1] + m_Line + strTableImage + m_Line + strTableImportantPrompt + m_Line
							+ strManagerIdea + m_Line + strReportEnd;
				}
			}
		}

		// 最终拼接
		strReportSimple = "<table cellpadding='0'cellspacing='0' width=" + tWidth * 8
				+ "border='0'><tr><td align='center'>" + strReportSimple + "</td></tr></table>";
		// strReportNormal = "<table cellpadding='0'cellspacing='0' width=" + tWidth * 8
		// + "border='0'><tr><td align='center'>" + strReportNormal +
		// "</td></tr></table>";
		strReportComplete = "<table cellpadding='0'cellspacing='0' width=" + tWidth * 8
				+ "border='0'><tr><td align='center'>" + strReportComplete + "</td></tr></table>";

		// 基本信息失败，就退出
		if (strUserInfo.equals("失败") || strTableInfo[0].equals("失败") || strManagerIdea.equals("失败")) {
			g_ReportResult.setUuid(info.getUuid());
			g_ReportResult.setMessage("失败");
			g_ReportResult.setReport_simple("");
			g_ReportResult.setReport_normal("");
			g_ReportResult.setReport_complete("");
			g_ReportResult.setReport_level("");
			g_ReportResult.setReport_prompt("");
		} else {
			g_ReportResult.setUuid(info.getUuid());
			g_ReportResult.setMessage("");
			g_ReportResult.setReport_simple(strReportSimple);
			g_ReportResult.setReport_complete(strReportComplete);
			g_ReportResult.setReport_level(strTableInfo[3]);
			g_ReportResult.setReport_prompt(strTableInfo[4]);
		}

		return g_ReportResult;
	}

	// 基础格式，位置
	private String subTitle(int vAlign, int vWidth) {
		String strR = "";
		switch (vAlign) {
		case 0:
			strR += " align='left'";
			break;
		case 1:
			strR += " align='center'";
			break;
		case 2:
			strR += " align='right'";
			break;
		}

		if (vWidth > 0) {
			strR += " style='font-size:" + sSize + "px; color:Black; Font-family:微软雅黑; font-weight:bold; width:"
					+ vWidth + "px'";
		} else {
			strR += " style='font-size:" + sSize + "px; color:Black; Font-family:微软雅黑; font-weight:bold;'";
		}

		return strR;
	}

	// 基础格式，内容标题
	private String addBlank(String vText) {
		try {
			String nBlank = "　";
			String hBlank = " ";

			String[] aChar = { "", "", "", "" };
			int i = 0;

			switch (vText.length()) {
			case 2:
			case 3:
				for (i = 0; i < vText.length(); i++) {
					aChar[i] = vText.substring(i, i + 1);
				}
				switch (vText.length()) {
				case 2:
					return aChar[0] + nBlank + nBlank + aChar[1];
				case 3:
					return aChar[0] + hBlank + aChar[1] + hBlank + aChar[2];
				}
				break;
			default:
				return vText;
			}

			return vText;
		} catch (ArithmeticException e) {
			return "错误" + e.toString();
		}
	}

	// 基础格式，内容文字
	private String subValue(int vAlign, int vWidth) {
		String strR = "";
		switch (vAlign) {
		case 0:
			strR += " align='left'";
			break;
		case 1:
			strR += " align='center'";
			break;
		case 2:
			strR += " align='right'";
			break;
		}

		if (vWidth > 0) {
			strR += " style='font-size:" + sSize + "px; color:#333000; width:" + vWidth + "px'";
		} else {
			strR += " style='font-size:" + sSize + "px;color:#333000'";
		}

		return strR;
	}

	// 单位信息及量表名称信息
	private String GetTableTitleReport(String vName) {
		return "<table cellpadding='0' cellspacing='0' width='100%' border='0'>"
				+ "<tr><td align='center' style='font-size:" + "16"
				+ "px; color:Black; Font-family:微软雅黑; font-weight:bold'>" + vName + "</td></tr>" + "</table>";
	}

	// 用户基本信息及测评基本信息
	private String UserInfo(TenantTableTaskInfo info, EUser user) {
		try {
			// 编号，姓名，性别，出生日期，年龄，文化程度，婚姻，科室，检查日期，2个固定项，测试耗时
			String strResult = "";
			strResult += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";
			strResult += "<tr><td" + subTitle(0, tWidth) + ">" + addBlank("编号") + "</td><td" + subValue(0, tWidth) + ">"
					+ user.getUser_name() + "</td>" + "<td" + subTitle(0, tWidth) + ">" + addBlank("姓名") + "</td><td"
					+ subValue(0, tWidth) + ">" + user.getReal_name() + "</td>" + "<td" + subTitle(0, tWidth) + ">"
					+ addBlank("性别") + "</td><td" + subValue(0, tWidth) + ">"
					+ AdminCommon.getGenderString(user.getUser_gender()) + "</td></tr>";
			if (user.getUser_birth() != null)
				strResult += "<tr><td" + subTitle(0, -1) + ">出生日期</td><td" + subValue(0, -1) + ">"
						+ DateTimeUtil.getStringFromUTC(user.getUser_birth()) + "</td>" + "<td" + subTitle(0, -1)
						+ ">测试日期</td><td" + subValue(0, -1) + ">"
						+ new SimpleDateFormat("yyyy-MM-dd")
								.format(info.getSubmit_date() == null ? new Date() : info.getSubmit_date())
						+ "</td>" + "<td" + subTitle(0, -1) + ">测试耗时</td><td" + subValue(0, -1) + ">"
						+ DateTimeUtil.getStringFromSeconds(info.getAnswer_time()) + "</td></tr>";
			else
				strResult += "<tr><td" + subTitle(0, -1) + ">出生日期</td><td" + subValue(0, -1) + ">" + "未知" + "</td>"
						+ "<td" + subTitle(0, -1) + ">测试日期</td><td" + subValue(0, -1) + ">"
						+ new SimpleDateFormat("yyyy-MM-dd")
								.format(info.getSubmit_date() == null ? new Date() : info.getSubmit_date())
						+ "</td>" + "<td" + subTitle(0, -1) + ">测试耗时</td><td" + subValue(0, -1) + ">"
						+ DateTimeUtil.getStringFromSeconds(info.getAnswer_time()) + "</td></tr>";

			strResult += "<tr><td" + subTitle(0, -1) + ">组织机构</td><td  colspan = 5" + subValue(0, -1) + ">"
					+ user.getFramework_name() + "</td>";

			strResult += "</table>";

			return strResult;
		} catch (ArithmeticException e) {
			return "失败";
		}

	}

	// 量表指导意见
	private String MultiCodeToManagerIdea(String vDiagAgg) {
		String strResult = "";
		String strTableDiagnosis = "";
		try {
			if (vDiagAgg.length() <= 0) {
				return strResult;
			}

			int i;
			String[] strCodeA = vDiagAgg.split("\\|");

			strResult += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";
			strResult += "<tr><td" + subTitle(0, -1) + ">测评结果</td></tr>";

			for (i = 0; i < strCodeA.length; i++) {
				SysTableDiagnosis diagnosis = getTableDiagnosis(strCodeA[i]);
				if (diagnosis == null) // Mmpi传入"前后回答有矛盾"特殊处理
					strTableDiagnosis = strCodeA[i];
				else
					strTableDiagnosis = diagnosis.getDiagnosis_content();
				if (strTableDiagnosis.length() > 0) {
					// strResult += "<tr><td" + subValue(0, -1) + ">" + tSpace + strTableDiagnosis +
					// "</td></tr>";
					// 癌症患者身心状态量表指导语中有“|”需要去掉，这个量表特殊
					strResult += "<tr><td" + subValue(0, -1) + ">" + tSpace + strTableDiagnosis.replace("|", "")
							+ "</td></tr>";
				}
			}

			strResult += "</table>";

			return strResult;
		} catch (ArithmeticException e) {
			return "失败";
		}
	}

	// 报告结尾
	private String GetTableEndingReport(String vManagerName) {
		return "<table cellpadding='0' cellspacing='0' width='100%' border='0'>" + "<tr><td" + subTitle(2, -1)
				+ ">(本报告仅供参考)</td></tr>"
				/* + "<tr><td" + subValue(2, -1) + ">签名：" + vManagerName + "</td></tr>" */
				+ "<tr><td" + subValue(2, -1) + ">报告日期：" + DateTimeUtil.getNowString() + "</td></tr>" + "</table>";
	}

	// 传入参数是类似“4.1.1”，其实就是 “**_d”的值，算出指导意见
	private SysTableDiagnosis getTableDiagnosis(String InfoD) {
		SysTableDiagnosis diagnosis = null;
		String[] args = InfoD.split("\\.");
		Map<String, Object> p_map = new HashMap<String, Object>();
		if (args.length == 3) {
			p_map.put("table_code", args[0]);
			p_map.put("factor_code", args[1]);
			p_map.put("factor_level_code", args[2]);
			diagnosis = mSysTableDiagnosisService.findTableDiagnosisByMap(p_map);
		}
		return diagnosis;
	}

	// 获取量表相应题号的题目
	private String getTableContentQuestion(String table_uuid, Integer index) {
		Map<String, Object> p_map = new HashMap<String, Object>();
		p_map.put("table_uuid", table_uuid);
		p_map.put("index", index - 1);
		SysTableContent content = sysTableContentService.getTableContentByUuid(p_map);
		return content.getQuestion();
	}

	private List<String> getTableContentQuestions(String table_uuid) {
		return sysTableContentService.listTableContents(table_uuid);
	}

	// 重点提示调用代码,会用到getTableContentQuestion这个函数
	private String getTableImportantPrompt(String vEnglish_name, String vTable_uuid, String vAnswer, int vSex,
			Map<String, Object> map) {
		String strResult = "";
		try {
			String strNothing = tSpace + tSpace + "无";
			// 5,6明尼苏达Mmpi，12，17抑郁自评Sds，19Beck抑郁Bdi，20流调用抑郁Ces，21纽卡斯尔抑郁Ndi
			// 22焦虑自评Sas，25汉密顿焦虑Hama，26贝克焦虑Bai，30社交回避Sad，33精神症状Cprs，34简明精神Bprs
			// 35躁狂Brms，38副反应Tess，40锥体外Reses，41日常生活Adl，46老年临床Scap

			int i, j, k;
			String strQuesCodeAgg = ""; // 要列出的题目编号
			String strContent = "";

			int intNum;
			String strText;

			/*
			 * String[] strAnswerA = vAnswer.split("@@"); String[] strSubA =
			 * strAnswerA[0].split("\\|");
			 */
			String[] strAnswerA;
			String[] strSubA;

			switch (vEnglish_name) {
			case "Tess":
				int intI;
				// 转换回原来格式
				String[] strTemp1 = vAnswer.split("\\|@");
				String strTemp2 = strTemp1[0] + "|" + strTemp1[1].split(",")[1].toString() + "|"
						+ strTemp1[2].split(",")[1].toString() + "@@" + strTemp1[1].split(",")[0].toString() + "@@"
						+ strTemp1[2].split(",")[0].toString();

				// 临时赋值，JAVA默认切割时为空就不增加数组长度
				String[] strAnswer_c_Temp = strTemp2.replaceAll("&", "\\|").split("@@");
				strAnswerA = new String[] { "", "", "" };
				for (intI = 0; intI < strAnswer_c_Temp.length; intI++) {
					strAnswerA[intI] = strAnswer_c_Temp[intI].trim();
				}

				strSubA = strAnswerA[0].toString().split("\\|");
				break;
			default:
				strAnswerA = vAnswer.split("@@");
				strSubA = strAnswerA[0].split("\\|");
				break;
			}

			String strTitle = "";

			List<String> questions = new ArrayList<>();

			switch (vEnglish_name) {
			case "Mmpi399":
			case "Mmpi566":
				// 明尼苏达Mmpi，因子T分>=60，每题只要得分
				// 以下情况不显示题目:1、弃权(Q)原始分>=31；2、诈分(F)原始分≥23
				// 分肯定回答和否定回答两类来显示
				// 选择“是”的题目
				// 选择“否”的题目
				if (true) {
					strTitle = "因子T分>=60分，得分的题目";

					if (Float.valueOf(String.valueOf(map.get("drop_o"))) < 31f
							&& Float.valueOf(String.valueOf(map.get("infra_o"))) < 23f) {
						questions = getTableContentQuestions(vTable_uuid);
						// String[] strFactorA = {"Hypoch", "Depre", "Hyste", "Psychop", "Mascu",
						// "Para", "Psychas", "Schi", "Hypoma", "Social"};
						String[] strFactorA = "Hypoch,Depre,Hyste,Psychop,Mascu,Para,Psychas,Schi,Hypoma,Social"
								.toLowerCase().split(",");
						// 1-选1+1，2-选2+1
						String[][] strQuesA = {
								{ "23,29,43,62,72,108,114,125,161,189,273",
										"2,3,7,9,18,51,55,63,68,103,130,153,155,163,175,188,190,192,230,243,274,281" },
								{ "5,32,41,43,52,67,86,104,130,138,142,158,159,182,189,193,236,259,288,290",
										"2,8,9,18,30,36,39,46,51,57,58,64,80,88,89,95,98,107,122,131,145,152,153,154,155,160,178,191,207,208,233,241,242,248,263,270,271,272,285,296" },
								{ "10,23,32,43,44,47,76,114,179,186,189,238,253",
										"2,3,6,7,8,9,12,26,30,51,55,71,89,93,103,107,109,124,128,129,136,137,141,147,153,160,162,163,170,172,174,175,180,188,190,192,201,213,230,234,243,265,267,274,279,289,292" },
								{ "16,21,24,32,33,35,38,42,61,67,84,94,102,106,110,118,127,215,216,224,239,244,245,284",
										"8,20,37,82,91,96,107,134,137,141,155,170,171,173,180,183,201,231,235,237,248,267,287,289,294,296" },
								{ "4,25,69,70,74,77,78,87,92,126,132,134,140,149,179,187,203,204,217,226,231,239,261,278,282,295,297,299",
										"1,19,26,28,79,80,81,89,99,112,115,116,117,120,133,144,179,198,213,314,219,221,223,229,249,254,260,262,264,280,283,300" },
								{ "16,24,27,35,110,121,123,127,151,157,158,202,275,284,291,293,299,305,314,317,326,338,341,364,365",
										"93,107,109,111,117,124,268,281,294,310,316,319,327,347,348" },
								{ "10,15,22,32,41,61,76,86,94,102,106,142,159,182,189,217,238,266,301,304,321,336,337,340,342,343,344,346,349,351,352,356,357,358,359,360,361,362,366",
										"3,8,36,122,152,164,178,329,353" },
								{ "15,22,40,41,47,52,76,97,104,121,156,157,159,168,179,182,194,202,210,212,238,241,251,259,266,273,282,291,297,301,303,307,308,311,312,315,320,323,324,325,328,331,332,333,334,335,339,341,345,349,350,352,354,355,356,360,363,364,366",
										"17,65,103,119,177,178,187,192,196,220,276,281,302,306,309,310,318,322,330" },
								{ "11,13,21,22,59,64,73,97,100,109,127,134,143,156,157,167,181,194,212,222,226,228,232,233,238,240,250,251,263,266,268,271,277,279,298",
										"101,105,111,119,120,148,166,171,180,267,289" },
								{ "32,67,82,111,117,124,138,147,171,172,180,201,236,267,278,292,304,316,321,332,336,342,357,369,370,373,376,378,379,385,389,393,398,399",
										"25,33,57,91,99,119,126,143,193,208,229,231,254,262,281,296,309,353,359,367,371,374,377,380,381,382,383,384,387,388,390,391,392,395,396,397" } };

						if (vSex == 0) // 男性化——女性化
						{
							strQuesA[4][0] = "4,25,70,74,77,78,87,92,126,132,133,134,140,149,187,203,204,217,226,239,261,278,282,295,299";
							strQuesA[4][1] = "1,19,26,28,69,79,80,81,89,99,112,115,116,117,120,144,176,179,198,213,214,219,221,223,229,231,249,254,260,262,264,280,283,297,300";
						}

						String[] strSubQuesA;
						String[] strYesOrNoA = { "", "" };
						String[] strLevelA = { "选<是>的题目", "选<否>的题目" };

						for (i = 0; i < strQuesA.length; i++) {
							if (Float.valueOf(String.valueOf(map.get(strFactorA[i] + "_s"))) > 60f) {
								for (j = 0; j < strQuesA[1].length; j++) {
									strSubQuesA = strQuesA[i][j].split(",");

									for (k = 0; k < strSubQuesA.length; k++) // 去掉重复元素
									{
										intNum = Integer.valueOf(strSubQuesA[k]) - 1;
										if (Integer.valueOf(strSubA[intNum]) == (j + 1)
												&& String.valueOf("," + strYesOrNoA[j])
														.indexOf("," + String.valueOf(intNum) + ",") < 0) {
											strYesOrNoA[j] += String.valueOf(intNum) + ",";
										}
									}
								}
							}
						}

						for (i = 0; i < strYesOrNoA.length; i++) {
							strContent += "<tr><td" + subTitle(0, -1) + "> " + tSpace + strLevelA[i] + "</td></tr>";
							if (strYesOrNoA[i].length() > 0) {
								strYesOrNoA[i] = strYesOrNoA[i].substring(0, strYesOrNoA[i].length() - 1);
								String[] strCodeA = strYesOrNoA[i].split(",");
								int[] intCodeA = new int[strCodeA.length];

								for (j = 0; j < strCodeA.length; j++) {
									intCodeA[j] = Integer.valueOf(strCodeA[j]);
								}

								// Array.Sort(intCodeA) '排序
								Arrays.sort(intCodeA);

								// 显示
								for (j = 0; j < intCodeA.length; j++) {
									strText = tSpace + tSpace + String.valueOf(intCodeA[j] + 1) + "."
											+ questions.get(intCodeA[j]);
									strContent += "<tr><td" + subValue(0, -1) + ">" + strText + "</td></tr>";
								}
							} else {
								strText = strNothing;
								strContent += "<tr><td" + subValue(0, -1) + ">" + strText + "</td></tr>";
							}
						}
					}
				}
				break;
			case "Scl90":
				// 90项症状Scl90，诊断为中度（平均分>=2.5），每题得分在中度及以上（>=3分）
				// 按因子名称，一个因子，一个因子的列出
				// 躯体化,强迫状态,人际关系敏感,抑郁,焦虑,敌对,恐怖,偏执,精神病性,其他
				if (true) {
					strTitle = "因子诊断为中度，得分在中度以上的题目";
					String[] strFactorNameA = { "躯体化", "强迫症状", "人际关系敏感", "抑郁", "焦虑", "敌对", "恐怖", "偏执", "精神病性", "其他项目" };
					// String[] strFactorA = {"Som", "Obs", "Int", "Dep", "Anx", "Hos", "Pno",
					// "Par", "Psy", "Other"};
					String[] strFactorA = "Som,Obs,Int,Dep,Anx,Hos,Pno,Par,Psy,Other".toLowerCase().split(",");
					String[] strQuesA = { "1,4,12,27,40,42,48,49,52,53,56,58", "3,9,10,28,38,45,46,51,55,65",
							"6,21,34,36,37,41,61,69,73", "5,14,15,20,22,26,29,30,31,32,54,71,79",
							"2,17,23,33,39,57,72,78,80,86", "11,24,63,67,74,81", "13,25,47,50,70,75,82",
							"8,18,43,68,76,83", "7,16,35,62,77,84,85,87,88,90", "19,44,59,60,64,66,89" };
					String[] strSubQuesA;

					// 存放最后符合条件的题目编号（10个因子，“中，重，极重”）
					String[][] strFactorLevelA = { { "", "", "" }, { "", "", "" }, { "", "", "" }, { "", "", "" },
							{ "", "", "" }, { "", "", "" }, { "", "", "" }, { "", "", "" }, { "", "", "" },
							{ "", "", "" } };
					String[] strLevelA = { "中", "重", "极重" };
					String[] strSubCodeA;

					questions = getTableContentQuestions(vTable_uuid);

					for (i = 0; i < strFactorA.length; i++) {
						if (Float.valueOf(String.valueOf(map.get(strFactorA[i] + "_ave"))) >= 2.5f) {
							strSubQuesA = strQuesA[i].split(",");

							for (j = 0; j < strSubQuesA.length; j++) {
								intNum = Integer.valueOf(strSubA[Integer.valueOf(strSubQuesA[j]) - 1]);
								if (intNum >= 3 && intNum <= 5) {
									strFactorLevelA[i][intNum - 3] += strSubQuesA[j] + ",";
								}
							}

							// 将这些内容，显示到报告中
							strContent += "<tr><td" + subTitle(0, -1) + "> " + strFactorNameA[i] + "：" + "</td></tr>"; // 因子名称

							for (j = strFactorLevelA[1].length - 1; j >= 0; j--) {

								strContent += "<tr><td" + subTitle(0, -1) + "> " + tSpace + strLevelA[j] + "</td></tr>"; // 因子程度

								if (strFactorLevelA[i][j].length() > 0) {
									strFactorLevelA[i][j] = strFactorLevelA[i][j].substring(0,
											strFactorLevelA[i][j].length() - 1);

									strSubCodeA = strFactorLevelA[i][j].split(","); // 得到题目编号
									for (k = 0; k < strSubCodeA.length; k++) {
										intNum = Integer.valueOf(strSubCodeA[k]) - 1;
										strText = tSpace + tSpace + String.valueOf(strSubCodeA[k]) + "."
												+ questions.get(intNum);
										strContent += "<tr><td" + subValue(0, -1) + ">" + strText + "</td></tr>";
									}
								} else {
									strText = strNothing;
									strContent += "<tr><td" + subValue(0, -1) + ">" + strText + "</td></tr>";
								}
							}
						}
					}
				}
				break;
			case "Sds":
				// 抑郁自评Sds，总分>=40，每题>=2分
				// 总粗分大于等于40分，列出大于等于2分题目的症状
				// 抑郁精神性——情感症状：1、3
				// 抑郁躯体障碍：2、4、5、6、7、8、9、10
				// 抑郁精神运动性障碍：12、13
				// 抑郁心理障碍：11、14、15、16、17、18、19、20
				if (true) {
					strTitle = "总粗分>=40分，>=2分的题目";
					if (Float.valueOf(String.valueOf(map.get("total_o"))) >= 40f) {
						String[] strQuesA = { "1,3", "2,4,5,6,7,8,9,10", "12,13", "11,14,15,16,17,18,19,20" };
						String[] strSubQuesA;
						String[] strIllA = { "忧郁", "晨重晚轻", "易哭", "睡眠障碍", "食欲减退", "性兴趣减退", "体重减轻", "便秘", "心悸", "易倦",
								"思考困难", "能力减退", "不安", "绝望", "易激惹", "决断困难", "无用感", "生活空虚感", "无价值感", "兴趣丧失" };
						String[] strFactorA = { "抑郁精神性", "抑郁躯体障碍", "抑郁精神运动性障碍", "抑郁心理障碍" };
						String[] strAnswer = { "没有或很少时间", "小部分时间", "相当多时间", "绝大部分或全部时间" };
						int intLevel;
						int intLocal;
						int[] intScoreA = { 0, 0, 0, 0 };

						for (i = 0; i < strQuesA.length; i++) {
							String strSubContent = "";
							strSubQuesA = strQuesA[i].split(",");
							for (j = 0; j < strSubQuesA.length; j++) {
								intLocal = Integer.valueOf(strSubQuesA[j]);
								intNum = Integer.valueOf(strSubA[intLocal - 1]);
								intLevel = -1;
								switch (intLocal) {
								case 2:
								case 5:
								case 6:
								case 11:
								case 12:
								case 14:
								case 16:
								case 17:
								case 18:
								case 20:
									if (intNum >= 1 && intNum <= 3) {
										intLevel = 5 - intNum;
									}
									intScoreA[i] += 5 - intNum;
									break;
								default:
									if (intNum >= 2 && intNum <= 4) {
										intLevel = intNum;
									}
									intScoreA[i] += intNum;
									break;
								}
								// 显示
								if (intLevel > 0) {
									strText = tSpace + tSpace + String.valueOf(intLocal) + "." + strIllA[intLocal - 1]
											+ "：" + strAnswer[intLevel - 1];// .Item("Answer" + intLevel);
									strSubContent += "<tr><td" + subValue(0, -1) + ">" + strText + "</td></tr>";
								}
							}

							strText = tSpace + strFactorA[i] + "，因子得分：" + intScoreA[i];
							strContent += "<tr><td" + subValue(0, -1) + ">" + strText + "</td></tr>" + strSubContent;
						}

					}
				}
				break;
			case "Bdi":
				// 2006-08-10
				// Beck抑郁Bdi，总分>=5，每题只要得分
				// 列出得分（得1分以上的）题目的症状，以及得分题目程度和选项内容。
				if (true) {
					strTitle = "总分>=5分，得分的题目";

					if (Float.valueOf(String.valueOf(map.get("total_o"))) >= 5f) {
						String[] strIllA = { "抑郁", "悲观", "失败感", "不满", "自罪感", "自我失望感", "消极倾向", "社交退缩", "犹豫不决", "自我形象改变",
								"工作困难", "疲乏感", "食欲丧失" };
						String[] strLevelA = { "轻度", "中度", "重度" };
						String[][] strAnswer = { { "我不感到忧郁", "我感到忧郁或沮丧", "我整天忧郁，无法摆脱", "我十分忧郁，已经忍受不住" },
								{ "我对未来并不悲观失望", "我感到前途不太乐观", "我感到我对前途不抱希望", "我感到今后毫无希望，不可能有所好转" },
								{ "我并无失败的感觉", "我觉得和大多数人相比我是失败的", "回顾我的一生，我觉得那是一连串的失败", "我觉得我是个彻底失败的人" },
								{ "我并不觉得有什么不满意", "我觉得我不能象平时那样享受生活", "任何事情都不能使我感到满意一些", "我对所有的事情都不满意" },
								{ "我没有特殊的内疚感", "我有时感到内疚或觉得自己没价值", "我感到非常内疚", "我觉得自己非常坏，一钱不值" },
								{ "我没有对自己感到失望", "我对自己感到失望", "我讨厌自己", "我憎恨自己" },
								{ "我没有要伤害自己的想法", "我感到还是死掉的好", "我考虑过自杀", "如果有机会，我还会杀了自己" },
								{ "我没失去和他人交往的兴趣", "和平时相比，我和他人交往的兴趣有所减退", "我已失去大部分和人交往的兴趣，我对他们没有感情",
										"我对他人全无兴趣，也完全不理睬别人" },
								{ "我能象平时一样做出决断", "我尝试避免做决定", "对我而言，做出决断十分困难", "我无法做出任何决断" },
								{ "我觉得我的形象一点也不比过去糟", "我担心我看起来老了，不吸引人了", "我觉得我的外表肯定变了，变得不具吸引力", "我感到我的形象丑陋且讨人厌" },
								{ "我能象平时那样工作", "我做事时，要花额外的努力才能开始", "我必须努力强迫自己，我方能干事", "我完全不能做事情" },
								{ "和以往相比，我并不容易疲倦", "我比过去容易觉得疲乏", "我做任何事都感到疲乏", "我太易疲乏了，不能干任何事" },
								{ "我的胃口不比过去差", "我的胃口没有过去那样好", "现在我的胃口比过去差多了", "我一点食欲都没有" } };

						for (i = 0; i < strSubA.length; i++) {
							intNum = Integer.valueOf(strSubA[i]);
							if (intNum >= 2 && intNum <= 4) {
								// 显示
								strText = tSpace + String.valueOf(i + 1) + "." + strIllA[i] + "："
										+ strLevelA[intNum - 2] + "，" + strAnswer[i][intNum - 1];
								strContent += "<tr><td" + subValue(0, -1) + ">" + strText + "</td></tr>";
							}
						}
					}
				}
				break;
			case "Ces":
				// 流调用抑郁Ces，总分>=20，每题>=1分
				// 列出：症状，得分频率
				if (true) {
					if (Float.valueOf(String.valueOf(map.get("total_o"))) >= 20f) {
						String[] strIllA = { "烦恼", "食欲减退", "苦闷感", "自卑感", "注意障碍", "情绪低沉", "乏力", "绝望感", "失败感", "害怕",
								"睡眠障碍", "无愉快感", "言语减少", "孤单感", "敌意感", "空虚感", "哭泣", "忧愁", "被憎厌感", "能力丧失" };
						String[] strLevelA = { "少有", "常有", "一直有" };
						int intLevel;

						for (i = 0; i < strSubA.length; i++) {
							intLevel = -1;
							intNum = Integer.valueOf(strSubA[i]);
							switch (i + 1) {
							case 4:
							case 8:
							case 12:
							case 16:
								if (intNum >= 1 && intNum <= 3) {
									intLevel = 3 - intNum;
								}
								break;
							default:
								if (intNum >= 2 && intNum <= 4) {
									intLevel = intNum - 2;
								}
								break;
							}

							// 显示
							if (intLevel >= 0) {
								strText = tSpace + String.valueOf(i + 1) + "." + strIllA[i] + "：" + strLevelA[intLevel]
										+ "。";
								strContent += "<tr><td" + subValue(0, -1) + ">" + strText + "</td></tr>";
							}
						}
					}
				}
				break;
			case "Ndi":
				// 纽卡斯尔抑郁Ndi，总分>=5，每题只要得分
				// 列出得分题目，以及相应程度（阳性、可疑）
				// 得分2分为阳性，得分1分为可疑
				if (true) {
					if (Float.valueOf(String.valueOf(map.get("total_o"))) >= 5f) {
						questions = getTableContentQuestions(vTable_uuid);

						String[] strLevelA = { "阳性", "可疑" };
						int intLevel;

						for (i = 0; i < strSubA.length; i++) {
							intLevel = -1;
							intNum = Integer.valueOf(strSubA[i]);
							switch (i + 1) {
							case 2:
							case 4:
							case 6:
							case 8:
								if (intNum == 1) {
									intLevel = 0;
								}
								break;
							case 7:
							case 9:
								break;
							default:
								if (intNum == 1) {
									intLevel = 1;
								}
								break;
							}

							// 显示
							if (intLevel >= 0) {
								strText = tSpace + String.valueOf(i + 1) + "." + questions.get(i) + "："
										+ strLevelA[intLevel];
								strContent += "<tr><td" + subValue(0, -1) + ">" + strText + "</td></tr>";
							}
						}
					}
				}
				break;
			case "Sas":
				// 焦虑自评Sas，总分>=40，每题>=2分
				// 躯体性焦虑：6、7、10、11、13、14、15、16、17、18
				// 精神性焦虑：1、2、3、4、5、8、9、12、19、20
				// 列出：症状，以及选项内容
				if (true) {
					if (Float.valueOf(String.valueOf(map.get("total_o"))) >= 40f) {
						int[][] intQuesA = { { 6, 7, 10, 11, 13, 14, 15, 16, 17, 18 },
								{ 1, 2, 3, 4, 5, 8, 9, 12, 19, 20 } };
						String[] strIllA = { "焦虑", "害怕", "惊恐", "发疯感", "不幸预感", "手足颤抖", "躯体疼痛", "乏力", "静坐不能", "心悸", "头昏",
								"晕厥感", "呼吸困难", "手足刺痛", "胃痛、消化不良", "尿意频数", "多汗", "面部潮红", "睡眠障碍", "恶梦" };
						String[] strFactorA = { "躯体性焦虑", "精神性焦虑" };
						String[] strAnswer = { "没有或很少时间", "小部分时间", "相当多时间", "绝大部分或全部时间" };
						int intLevel;
						int[] intScoreA = { 0, 0 };

						for (i = 0; i < intQuesA.length; i++) {
							String strSubContent = "";
							for (j = 0; j < intQuesA[1].length; j++) {
								intLevel = -1;
								intNum = Integer.valueOf(strSubA[intQuesA[i][j] - 1]);
								switch (intQuesA[i][j]) {
								case 5:
								case 9:
								case 13:
								case 17:
								case 19:
									if (intNum >= 1 && intNum <= 3) {
										intLevel = 5 - intNum;
									}
									intScoreA[i] += 5 - intNum;
									break;
								default:
									if (intNum >= 2 && intNum <= 4) {
										intLevel = intNum;
									}
									intScoreA[i] += intNum;
									break;
								}

								// 显示
								if (intLevel > 0) {
									strText = tSpace + tSpace + String.valueOf(intQuesA[i][j]) + "."
											+ strIllA[intQuesA[i][j] - 1] + "：" + strAnswer[intLevel - 1];
									strSubContent += "<tr><td" + subValue(0, -1) + ">" + strText + "</td></tr>";

								}
							}
							strText = tSpace + strFactorA[i] + "，因子得分：" + intScoreA[i];
							strContent += "<tr><td" + subTitle(0, -1) + ">" + strText + "</td></tr>" + strSubContent;
						}
					}
				}
				break;
			case "Hama":
				// 汉密顿焦虑Hama，总分>=14，每题>=2分
				// 躯体性焦虑题目：7、8、9、10、11、12、13
				// 精神性焦虑题目：1、2、3、4、5、6、14
				if (true) {
					if (Float.valueOf(String.valueOf(map.get("total_o"))) >= 14f) {
						int[][] intQuesA = { { 7, 8, 9, 10, 11, 12, 13 }, { 1, 2, 3, 4, 5, 6, 14 } };
						String[] strFactorA = { "躯体性焦虑", "精神性焦虑" };
						String[] strLevelA = { "极重", "重度", "中度" };
						String[][] strSubContentA = { { "", "", "" }, { "", "", "" } };

						questions = getTableContentQuestions(vTable_uuid);

						for (i = 0; i < intQuesA.length; i++) {
							for (j = 0; j < intQuesA[1].length; j++) {
								intNum = Integer.valueOf(strSubA[intQuesA[i][j] - 1]);
								if (intNum >= 3 && intNum <= 5) {
									strSubContentA[i][5 - intNum] += tSpace + tSpace + String.valueOf(intQuesA[i][j])
											+ "." + questions.get(intQuesA[i][j] - 1) + "<br />";
								}
							}

							// 显示
							strContent += "<tr><td" + subTitle(0, -1) + ">" + strFactorA[i] + "</td></tr>";
							for (j = 0; j < strSubContentA[1].length; j++) {
								strText = tSpace + strLevelA[j];
								strContent += "<tr><td" + subTitle(0, -1) + ">" + strText + "</td></tr>";
								if (strSubContentA[i][j].length() > 0) {
									strContent += "<tr><td" + subValue(0, -1) + ">" + strSubContentA[i][j]
											+ "</td></tr>";
								} else {
									strContent += "<tr><td" + subValue(0, -1) + ">" + strNothing + "</td></tr>";
								}
							}
						}
					}
				}
				break;
			case "Bai":
				// 贝克焦虑Bai，每题>=3分
				// 分中度和重度分别列出
				if (true) {
					String[] strLevelA = { "重度", "中度" };
					String[] strCodeAggA = { "", "" };

					questions = getTableContentQuestions(vTable_uuid);

					for (i = 0; i < strSubA.length; i++) {
						intNum = Integer.valueOf(strSubA[i]);
						if (intNum >= 3 && intNum <= 4) {
							strCodeAggA[4 - intNum] += String.valueOf(i) + ",";
						}
					}

					// 显示
					for (i = 0; i < strCodeAggA.length; i++) {
						strContent += "<tr><td" + subTitle(0, -1) + "> " + tSpace + strLevelA[i] + "</td></tr>";
						if (strCodeAggA[i].length() > 0) {
							strCodeAggA[i] = strCodeAggA[i].substring(0, strCodeAggA[i].length() - 1); // 2006-08-18
							String[] strCodeA = strCodeAggA[i].split(",");
							for (j = 0; j < strCodeA.length; j++) {
								strText = tSpace + tSpace + String.valueOf(Integer.valueOf(strCodeA[j]) + 1) + "."
										+ String.valueOf(questions.get(Integer.valueOf(strCodeA[j])));
								strContent += "<tr><td" + subValue(0, -1) + ">" + strText + "</td></tr>";
							}
						} else {
							strText = strNothing;
							strContent += "<tr><td" + subValue(0, -1) + ">" + strText + "</td></tr>";
						}
					}
				}
				break;
			case "Sad":
				// 社交回避Sad，总分>=14，每题只要得分
				// 社交回避题目：2、4、8、9、13、17、18、19、21、22、24、25、26、27
				// 社交苦恼题目：1、3、5、6、7、10、11、12、14、15、16、20、23、28
				// 1-肯定回答，2-否定回答
				if (true) {
					if (Float.valueOf(String.valueOf(map.get("total_o"))) >= 14f) {
						int[][] intQuesA = { { 2, 4, 8, 9, 13, 17, 18, 19, 21, 22, 24, 25, 26, 27 },
								{ 1, 3, 5, 6, 7, 10, 11, 12, 14, 15, 16, 20, 23, 28 } };
						String[] strFactorA = { "社交回避", "社交苦恼" };
						int[] intFactor = { 0, 0 };
						int intValue;

						questions = getTableContentQuestions(vTable_uuid);

						for (i = 0; i < intQuesA.length; i++) {
							String[] strYesOrNoA = { "", "" };
							for (j = 0; j < intQuesA[1].length; j++) {
								switch (intQuesA[i][j]) {
								case 2:
								case 5:
								case 8:
								case 10:
								case 11:
								case 13:
								case 14:
								case 16:
								case 18:
								case 20:
								case 21:
								case 23:
								case 24:
								case 26:
									intValue = 1;
									break;
								default:
									intValue = 2;
									break;

								}
								intNum = intQuesA[i][j] - 1;
								if (Integer.valueOf(strSubA[intNum]) == intValue) {
									intFactor[i] += 1; // 2006-08-14
									strYesOrNoA[intValue - 1] += tSpace + tSpace + String.valueOf(intNum + 1) + "."
											+ questions.get(intNum) + "<br />";
								}
							}

							// 显示
							String[] strSaidA = { "肯定回答", "否定回答" };
							strText = strFactorA[i] + "，因子得分： " + String.valueOf(intFactor[i]);
							strContent += "<tr><td" + subTitle(0, -1) + ">" + strText + "</td></tr>";

							for (j = 0; j < strSaidA.length; j++) {
								strText = tSpace + strSaidA[j] + "：";
								strContent += "<tr><td" + subTitle(0, -1) + ">" + strText + "</td></tr>";
								if (strYesOrNoA[j].length() > 0) {
									strContent += "<tr><td" + subValue(0, -1) + ">" + strYesOrNoA[j] + "</td></tr>";
								} else {
									strContent += "<tr><td" + subValue(0, -1) + ">" + strNothing + "</td></tr>";
								}
							}
						}
					}
				}
				break;
			case "Cprs":
				// 精神症状Cprs，每题>=2分，列出得分题目
				// 精神分裂症量表：1、3、5、6、13、16、19、28、29、30、31、33、36、37、38、40、45、50、54、55、57
				// 抑郁症分量表：1、3、5、6、7、9、13、14、15、16、18、19、23、25、41、61、63
				if (true) {
					String[] strQuesA = { "1,3,5,6,13,16,19,28,29,30,31,33,36,37,38,40,45,50,54,55,57",
							"1,3,5,6,7,9,13,14,15,16,18,19,23,25,41,61,63" };
					String[] strFactorA = { "精神分裂症量表", "抑郁症分量表" };

					questions = getTableContentQuestions(vTable_uuid);

					for (i = 0; i < strQuesA.length; i++) {
						String[] strSubQuesA = strQuesA[i].split(",");
						String[] strThorFoA = { "", "" };
						int intLocal;

						for (j = 0; j < strSubQuesA.length; j++) {
							intNum = Integer.valueOf(strSubQuesA[j]) - 1;
							if (Integer.valueOf(strSubA[intNum]) >= 3 && Integer.valueOf(strSubA[intNum]) <= 4) {
								intLocal = 4 - Integer.valueOf(strSubA[intNum]);
								strThorFoA[intLocal] += tSpace + tSpace + strSubQuesA[j] + "." + questions.get(intNum)
										+ "<br />";
							}
						}

						// 显示
						String[] strLevelA1 = { "严重", "肯定有" };
						strContent += "<tr><td" + subTitle(0, -1) + ">" + strFactorA[i] + "：" + "</td></tr>";

						for (j = 0; j < strLevelA1.length; j++) {
							strText = tSpace + strLevelA1[j] + "：";
							strContent += "<tr><td" + subTitle(0, -1) + ">" + strText + "</td></tr>";
							if (strThorFoA[j].length() > 0) {
								strContent += "<tr><td" + subValue(0, -1) + ">" + strThorFoA[j] + "</td></tr>";
							} else {
								strContent += "<tr><td" + subValue(0, -1) + ">" + strNothing + "</td></tr>";
							}
						}
					}
				}
				break;
			case "Bprs":
				// 简明精神Bprs，每题>=3分
				// 焦虑忧郁：1、2、5、9
				// 缺乏活力：3、13、16、18
				// 思维障碍：4、8、12、15
				// 激活性：6、7、17
				// 敌对猜疑：10、11、14
				if (true) {
					String[] strQuesA = { "1,2,5,9", "3,13,16,18", "4,8,12,15", "6,7,17", "10,11,14" };
					String[] strFactorA = { "焦虑忧郁", "缺乏活力", "思维障碍", "激活性", "敌对猜疑" };
					String[] strLevelA = { "极重", "重度", "偏重", "中度", "轻度" };

					questions = getTableContentQuestions(vTable_uuid);

					for (i = 0; i < strQuesA.length; i++) {
						String[] strSubQuesA = strQuesA[i].split(",");
						String[] strCodeAgg = { "", "", "", "", "" };
						for (j = 0; j < strSubQuesA.length; j++) {
							intNum = Integer.valueOf(strSubQuesA[j]) - 1;
							if (Integer.valueOf(strSubA[intNum]) >= 3 && Integer.valueOf(strSubA[intNum]) <= 7) {
								strCodeAgg[7 - Integer.valueOf(strSubA[intNum])] += intNum + ",";
							}
						}
						// 显示
						strContent += "<tr><td" + subTitle(0, -1) + "> " + strFactorA[i] + "</td></tr>";
						for (j = 0; j < strLevelA.length; j++) {
							strContent += "<tr><td" + subTitle(0, -1) + "> " + tSpace + strLevelA[j] + "</td></tr>";
							if (strCodeAgg[j].length() > 0) {
								strCodeAgg[j] = strCodeAgg[j].substring(0, strCodeAgg[j].length() - 1);
								String[] strCodeA = strCodeAgg[j].split(",");
								for (k = 0; k < strCodeA.length; k++) {
									// 只要显示题目的标题部分，用“（”区分
									String[] strTempA = questions.get(Integer.valueOf(strCodeA[k])).split("（");
									strText = tSpace + tSpace + String.valueOf(Integer.valueOf(strCodeA[k]) + 1) + "."
											+ strTempA[0];
									strContent += "<tr><td" + subValue(0, -1) + ">" + strText + "</td></tr>";
								}

							} else {
								strText = strNothing;
								strContent += "<tr><td" + subValue(0, -1) + ">" + strText + "</td></tr>";
							}
						}

					}
				}
				break;
			case "Brms":
				// 躁狂Brms，总分>=6，每题只要得分
				// 列出：题目，程度，选项内容
				if (true) {
					if (Float.valueOf(String.valueOf(map.get("total_o"))) >= 6f) {
						String[] strLevelA = { "轻度", "中度", "较重", "极重" };
						String[][] strAnswer = {
								{ "无该项症状或与患者正常时的水平相仿", "动作稍多，表情活跃", "动作多，姿势活跃", "动作极多，会谈时曾起立活动", "动个不停，虽予劝说仍坐立不安宁" },
								{ "无该项症状或与患者正常时的水平相仿", "话较多", "话多，几无自动停顿", "很难打断", "无法打断" },
								{ "无该项症状或与患者正常时的水平相仿", "描述、修饰或解释的词句过多", "内容稍散漫或离题，有意联，音联或双关语", "思维散漫无序",
										"思维不连贯，内容无法理解" },
								{ "无该项症状或与患者正常时的水平相仿", "说话声音高", "大声说话，隔开一段距离仍能听到", "语音极高夹带歌声或躁音", "呼喊或尖叫" },
								{ "无该项症状或与患者正常时的水平相仿", "稍急躁或易激惹，能控制", "明显急躁，易激惹或易怒", "有威胁性行为，但能被安抚", "狂暴，冲动或破坏行为" },
								{ "无该项症状或与患者正常时的水平相仿", "略高涨，乐观", "高涨，爱开玩笑，易笑", "明显高涨，洋洋自得", "极高涨，和环境不协调" },
								{ "无该项症状或与患者正常时的水平相仿", "略高", "高，常自诩自夸", "有不合实际的夸大观念", "有难以纠正的夸大妄想" },
								{ "无该项症状或与患者正常时的水平相仿", "稍有爱管闲事或指手划脚倾向", "爱管闲事，好争辩", "爱发号施令，指挥他人", "专横，与环境不协调" },
								{ "无该项症状或与患者正常时的水平相仿", "睡眠时间减少25%", "睡眠时间减少50%", "睡眠时间减少75%", "整夜不眠" },
								{ "无该项症状或与患者正常时的水平相仿", "兴趣稍增强，有些轻浮言行", "性兴趣增强，有明显轻浮言行", "性兴趣显著增强，有严重调戏异性，或卖弄风情言行",
										"整日专注于性活动" },
								{ "无该项症状或与患者正常时的水平相仿", "工作质量略有下降", "工作质量明显下降", "无法继续工作，或在医院内尚能参加活动数小时",
										"日常活动不能自理，或不能参加病房活动" },
								{ "无该项症状或与患者正常时的水平相仿", "偶有或可疑", "肯定存在，每天≥3次", "经常出现", "行为受幻觉支配" },
								{ "无该项症状或与患者正常时的水平相仿", "偶有或可疑", "妄想肯定，可用情绪解释", "妄想肯定，难以用情绪解释", "出现幻觉的妄想" } };

						questions = getTableContentQuestions(vTable_uuid);

						for (i = 0; i < strSubA.length; i++) {
							intNum = Integer.valueOf(strSubA[i]);
							if (intNum >= 2 && intNum <= 5) {
								strText = tSpace + String.valueOf(i + 1) + "." + questions.get(i) + "：" + oSpace
										+ strLevelA[intNum - 2] + oSpace + strAnswer[i][intNum - 1];
								strContent += "<tr><td" + subValue(0, -1) + ">" + strText + "</td></tr>";
							}
						}
					}
				}
				break;
			case "Tess":
				// 副反应Tess, 每题选4或5选项的
				if (true) {
					String[] strLevelA = { "行为毒性", "化验异常", "神经系", "植物性神经系统", "心血管系", "其它" };
					String strTempContent = "";
					String[][] strAnswer = {
							{ "无该项症状", "极轻或可疑", "轻度", "仅见于晚上，短暂", "持续至白天", "无", "加强观察", "予拮抗药", "减少剂量", "减少剂量并予拮抗药",
									"暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "有焦虑或恐惧", "有非持续性的激越性运动行为", "持续激越，如捶首，顿足和搓手等", "无", "加强观察", "予拮抗药",
									"减少剂量", "减少剂量并予拮抗药", "暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "问出来的心境抑郁", "主动诉述抑郁绝望，易哭", "伴阻滞的符合诊断标准的重症抑郁发作", "无", "加强观察", "予拮抗药",
									"减少剂量", "减少剂量并予拮抗药", "暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "非持续性，能自行控制", "持续性，不需外力控制", "持续，需他人干涉", "无", "加强观察", "予拮抗药", "减少剂量",
									"减少剂量并予拮抗药", "暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "主动活动减少", "需外力推动才活动", "木僵或亚木僵", "无", "加强观察", "予拮抗药", "减少剂量",
									"减少剂量并予拮抗药", "暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "比平时睡眠减少2小时", "减少3～6小时", "减少6小时以上", "无", "加强观察", "予拮抗药", "减少剂量",
									"减少剂量并予拮抗药", "暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "白天嗜睡或睡觉2小时", "白天睡眠3～8小时", "白天睡8小时以上", "无", "加强观察", "予拮抗药", "减少剂量",
									"减少剂量并予拮抗药", "暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "轻度", "血象化验异常，如白细胞减少", "严重异常 如白细胞缺乏", "无", "加强观察", "予拮抗药", "减少剂量",
									"减少剂量并予拮抗药", "暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "轻度", "化验异常", "黄疸", "无", "加强观察", "予拮抗药", "减少剂量", "减少剂量并予拮抗药", "暂停治疗",
									"中止治疗" },
							{ "无该项症状", "极轻或可疑", "轻度", "化验结果为肯定异常", "严重异常", "无", "加强观察", "予拮抗药", "减少剂量", "减少剂量并予拮抗药",
									"暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "肌张力轻度增高，不影响活动", "肌张力明显增高未用拮抗药", "肌张力极高，即使使用拮抗药亦不能逆转", "无", "加强观察",
									"予拮抗药", "减少剂量", "减少剂量并予拮抗药", "暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "自觉有震颤感，或闭目平伸双手有轻度震颤", "明显可见的震颤，影响精细活动", "震颤严重，影响生活，如无法进食", "无", "加强观察",
									"予拮抗药", "减少剂量", "减少剂量并予拮抗药", "暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "有，但不影响活动", "影响活动但不影响生活", "影响生活", "无", "加强观察", "予拮抗药", "减少剂量",
									"减少剂量并予拮抗药", "暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "自觉心烦，缺乏耐心，能自控", "因缺乏耐心，会谈时或工作中起立行走", "无法静坐，无法完成任务，不能自控", "无", "加强观察",
									"予拮抗药", "减少剂量", "减少剂量并予拮抗药", "暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "主诉口腔粘膜干燥", "可查出的口腔粘膜干燥(对生活无严重影响)", "可明显查出的口腔粘膜干燥(严重影响病人的活动和生活)", "无",
									"加强观察", "予拮抗药", "减少剂量", "减少剂量并予拮抗药", "暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "自感鼻塞", "可见或可证实的鼻塞(如说话的声音)(对生活无严重影响)", "可见或可证实的鼻塞(严重影响病人的活动和生活)", "无",
									"加强观察", "予拮抗药", "减少剂量", "减少剂量并予拮抗药", "暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "只是主诉", "影响视力的清晰度", "累及日常活动，如绊倒东西等", "无", "加强观察", "予拮抗药", "减少剂量",
									"减少剂量并予拮抗药", "暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "便秘36小时以上", "4天以上的便秘", "需手通大便", "无", "加强观察", "予拮抗药", "减少剂量",
									"减少剂量并予拮抗药", "暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "轻度", "唾液增多", "淌口水", "无", "加强观察", "予拮抗药", "减少剂量", "减少剂量并予拮抗药", "暂停治疗",
									"中止治疗" },
							{ "无该项症状", "极轻或可疑", "汗比平时多，或阵阵出汗", "汗比平时多，或阵阵出汗(对生活有些影响)", "面部大汗淋漓", "无", "加强观察", "予拮抗药",
									"减少剂量", "减少剂量并予拮抗药", "暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "轻度", "恶心", "呕吐", "无", "加强观察", "予拮抗药", "减少剂量", "减少剂量并予拮抗药", "暂停治疗",
									"中止治疗" },
							{ "无该项症状", "极轻或可疑", "一天2次", "一天3～5次", "一天5次以上", "无", "加强观察", "予拮抗药", "减少剂量", "减少剂量并予拮抗药",
									"暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "比平时低10％以上", "降低20％以上", "低至难以测出", "无", "加强观察", "予拮抗药", "减少剂量",
									"减少剂量并予拮抗药", "暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "有头昏头晕感", "伴失平衡感的头昏和头晕", "晕厥，失去知觉", "无", "加强观察", "予拮抗药", "减少剂量",
									"减少剂量并予拮抗药", "暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "心率90至100次/分", "100至120次/分", "120次/分以上", "无", "加强观察", "予拮抗药", "减少剂量",
									"减少剂量并予拮抗药", "暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "140/90以上", "160/100以上", "200/120以上", "无", "加强观察", "予拮抗药", "减少剂量",
									"减少剂量并予拮抗药", "暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "有异常，但无临床意义", "具临床意义的异常", "伴严重后果的异常", "无", "加强观察", "予拮抗药", "减少剂量",
									"减少剂量并予拮抗药", "暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "日光过敏", "暂时性的发痒或红斑", "过敏性皮炎", "无", "加强观察", "予拮抗药", "减少剂量", "减少剂量并予拮抗药",
									"暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "一月内增加5磅", "增加6至10磅", "增加10磅以上", "无", "加强观察", "予拮抗药", "减少剂量",
									"减少剂量并予拮抗药", "暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "一月内减轻5磅", "减轻6至10磅", "减轻10磅以上", "无", "加强观察", "予拮抗药", "减少剂量",
									"减少剂量并予拮抗药", "暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "每天食量仅相当于两餐的数量", "相当于一餐的数量", "不进食", "无", "加强观察", "予拮抗药", "减少剂量",
									"减少剂量并予拮抗药", "暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "仅为主诉", "有痛苦感", "因而丧失功能或无法活动", "无", "加强观察", "予拮抗药", "减少剂量", "减少剂量并予拮抗药",
									"暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "由检查引出的TD症状", "自发的TD症状", "明显影响功能或活动", "无", "加强观察", "予拮抗药", "减少剂量",
									"减少剂量并予拮抗药", "暂停治疗", "中止治疗" },
							{ "无该项症状", "极轻或可疑", "轻度", "中度", "重度", "无", "加强观察", "予拮抗药", "减少剂量", "减少剂量并予拮抗药", "暂停治疗",
									"中止治疗" },
							{ "无该项症状", "极轻或可疑", "轻度", "中度", "重度", "无", "加强观察", "予拮抗药", "减少剂量", "减少剂量并予拮抗药", "暂停治疗",
									"中止治疗" },
							{ "无", "轻", "中", "重", "不肯定", "无", "轻", "中", "重", "不肯定", "NULL", "NULL" } };

					questions = getTableContentQuestions(vTable_uuid);

					for (i = 0; i < strSubA.length - 6; i += 2) // 最后三题，不记入
					{
						if (Integer.valueOf(strSubA[i]) >= 4) {
							strQuesCodeAgg = String.valueOf(i / 2);
							strTempContent += tSpace + tSpace + String.valueOf(Integer.valueOf(strQuesCodeAgg) + 1)
									+ "." + questions.get(Integer.valueOf(strQuesCodeAgg)) + "："
									+ strAnswer[Integer.valueOf(strQuesCodeAgg)][Integer.valueOf(strSubA[i]) - 1]
									+ "<br />";
						}

						int[] intC = { 6, 9, 13, 21, 26, 32 };
						int intIndex = -1;
						for (j = 0; j < intC.length; j++) {
							if (Integer.valueOf((i / 2)) == intC[j]) {
								intIndex = j;
								break;
							}
						}

						if (intIndex >= 0) {
							if (!strTempContent.equals("")) {
								strContent += "<tr><td" + subTitle(0, -1) + ">" + tSpace + strLevelA[intIndex]
										+ "</td></tr>";
								strContent += "<tr><td" + subValue(0, -1) + ">" + strTempContent + "</td></tr>";
								strTempContent = "";
							}
						}
					}
				}
				break;
			case "Reses":
				// 锥体外Reses，总分>=8，程度“无”不显示
				if (true) {
					if (Float.valueOf(String.valueOf(map.get("total_o"))) >= 8f) {
						String[] strLevelA = { "重度", "中度", "轻度", "可疑" };
						String[] strCodeAggA = { "", "", "", "" };
						questions = getTableContentQuestions(vTable_uuid);
						for (i = 0; i < strSubA.length; i++) {
							intNum = Integer.valueOf(strSubA[i]);
							if (intNum >= 2 && intNum <= 5) {
								strCodeAggA[5 - intNum] += String.valueOf(i) + ",";
							}
						}
						// 显示
						for (i = 0; i < strCodeAggA.length; i++) {
							strContent += "<tr><td" + subTitle(0, -1) + "> " + tSpace + strLevelA[i] + "</td></tr>";
							if (strCodeAggA[i].length() > 0) {
								strCodeAggA[i] = strCodeAggA[i].substring(0, strCodeAggA[i].length() - 1);
								String[] strCodeA = strCodeAggA[i].split(",");
								for (j = 0; j < strCodeA.length; j++) {
									String[] halfQC = questions.get(Integer.valueOf(strCodeA[j])).split("：");
									strText = tSpace + tSpace + strCodeA[j] + "." + halfQC[0];
									strContent += "<tr><td" + subValue(0, -1) + ">" + strText + "</td></tr>";
								}
							} else {
								strText = strNothing;
								strContent += "<tr><td" + subValue(0, -1) + ">" + strText + "</td></tr>";
							}
						}
					}
				}
				break;
			case "Adl":
				// 日常生活Adl
				// 总分大于等于22分或2项及2项以上大于等于3分的，列出得分2分以上的题目及选项内容
				// 躯体生活自理题目：2、6、7、8、10、12
				// 工具性日常生活能力题目：1、3、4、5、9、11、13、14
				// 列出：躯体生活自理:6.吃饭，情况: 根本没办法做
				// 工具性日常生活能力:14.处理自己钱财，情况: 根本没办法做
				if (true) {
					int intCount = 0; // 计数
					for (i = 0; i < strSubA.length; i++) {
						if (Integer.valueOf(strSubA[i]) >= 3) {
							intCount += 1;
						}
					}

					if (Float.valueOf(String.valueOf(map.get("total_o"))) >= 22f || intCount >= 2) {
						String[] strQuesA = { "2,6,7,8,10,12", "1,3,4,5,9,11,13,14" };
						String[] strFactorA = { "躯体生活自理", "工具性日常生活能力" };
						String[] strLevela = "有些困难,需要帮助,根本无法做".split(",");
						String strSubContent;

						questions = getTableContentQuestions(vTable_uuid);

						for (i = 0; i < strQuesA.length; i++) {
							String[] strSubQuesA = strQuesA[i].split(",");
							strSubContent = "";

							for (j = 0; j < strSubQuesA.length; j++) {
								intNum = Integer.valueOf(strSubQuesA[j]) - 1;
								if (Integer.valueOf(strSubA[intNum]) >= 2) {
									strSubContent += tSpace + tSpace + String.valueOf(intNum + 1) + "."
											+ questions.get(intNum) + oSpace + "情况："
											+ strLevela[Integer.valueOf(strSubA[intNum]) - 2] + "<br />";
								}
							}
							if (strSubContent.length() > 0) {
								strContent += "<tr><td" + subTitle(0, -1) + "> " + tSpace + strFactorA[i]
										+ "</td></tr>";
								strContent += "<tr><td" + subValue(0, -1) + "> " + strSubContent + "</td></tr>";
							}
						}
					}
				}
				break;
			case "Scap":
				// 老年临床Scap，选项为轻度及以上
				// 列出选项轻度以上（极重，重度，偏重，中度，轻度）

				String[] strLevelA = { "极重", "重度", "偏重", "中度", "轻度" };
				String[] strCodeAggA = { "", "", "", "", "" };

				questions = getTableContentQuestions(vTable_uuid);

				for (i = 0; i < strSubA.length; i++) {
					intNum = Integer.valueOf(strSubA[i]);
					if (intNum >= 3 && intNum <= 7) {
						strCodeAggA[7 - intNum] += String.valueOf(i) + ",";
					}
				}

				// 显示
				for (i = 0; i < strCodeAggA.length; i++) {
					strContent += "<tr><td" + subTitle(0, -1) + "> " + tSpace + strLevelA[i] + "</td></tr>";
					if (strCodeAggA[i].length() > 0) {
						strCodeAggA[i] = strCodeAggA[i].substring(0, strCodeAggA[i].length() - 1);
						String[] strCodeA = strCodeAggA[i].split(",");
						for (j = 0; j < strCodeA.length; j++) {
							strText = tSpace + tSpace + String.valueOf(Integer.valueOf(strCodeA[j]) + 1) + "."
									+ questions.get(Integer.valueOf(strCodeA[j]));
							strContent += "<tr><td" + subValue(0, -1) + ">" + strText + "</td></tr>";
						}
					} else {
						strText = strNothing;
						strContent += "<tr><td" + subValue(0, -1) + ">" + strText + "</td></tr>";
					}
				}

				break;
			default:
				break;
			}
			if (strContent.length() > 0) {
				strResult += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";
				strResult += "<tr><td" + subTitle(0, -1) + ">重点提示：</td></tr>";
				strResult += strContent;
				strResult += "</table>";
			}

			return strResult;
		} catch (ArithmeticException e) {
			return "失败";
		}
	}

	// 八、艾森克个性测验(儿童)Xepq
	private String[] GetXepqReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "精神质,内外向,神经质,掩饰程度".split(",");
			String[] gdName = "P,E,N,L".split(",");
			String[] geName = "Jsz,Nwx,Sjz,Yscd".toLowerCase().split(",");

			String[] gvName = {};
			switch (g_CorE) {
			case 1:
				gvName = gcName;
				break;
			case 2:
				gvName = gdName;
				break;
			}

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">指标</td><td" + subTitle(1, tWidth * 2)
						+ ">原始分</td><td" + subTitle(1, -1) + ">标准分</td></tr>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, -1) + ">" + gvName[i] + "</td>" + "<td" + subValue(1, -1)
							+ ">" + map.get(geName[i] + "_o") + "</td>" + "<td" + subValue(1, -1) + ">"
							+ map.get(geName[i] + "_s") + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			String strCode = "";
			for (i = 0; i < gcName.length; i++) {
				strCode += map.get(geName[i] + "_d") + "|";
			}

			if (strCode.length() > 0) {
				strCode = strCode.substring(0, strCode.length() - 1);
			}

			strResult[2] = strCode;

			// 预警
			for (i = 0; i < gcName.length; i++) {
				if (i % 2 == 0) {
					if (Float.valueOf(String.valueOf((map.get(geName[i] + "_s")))) >= 63.4) {
						strResult[3] = "*";
						strResult[4] += gcName[i].toString() + "异常，";
					}
				}
			}

			if (strResult[4].length() > 0) {
				strResult[4] = strResult[4].substring(0, strResult[4].length() - 1);
			} else {
				strResult[3] = "0";
				strResult[4] = "正常";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 九、爱德华个性偏好测验Epps
	private String[] GetEppsReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i, j;
			String[] gcName = "成就欲,崇拜欲,秩序性,表现欲,自主性,亲近性,探究欲,求助性,支配性,谦卑性,慈善性,变异性,坚毅性,性　爱,攻击性,一致性".split(",");
			String[] gdName = "Ach,Def,Ord,Exh,Aut,Aff,Int,Suc,Dom,Aba,Nur,Chg,End,Het,Agg,Con".split(",");
			String[] geName = "Cjy,Cby,Cxx,Bxy,Zzx,Qjx,Tjy,Qzx,Zpx,Qbx,Csx,Byx,Jyx,Xa,Gjx,Yzx".toLowerCase().split(",");

			String[] gvName = {};
			switch (g_CorE) {
			case 1:
				gvName = gcName;
				break;
			case 2:
				gvName = gdName;
				break;
			}

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr>";
				for (i = 0; i < 2; i++) {
					strResult[1] += "<td" + subTitle(1, tWidth) + ">指标</td><td" + subTitle(1, tWidth) + ">原始分</td><td"
							+ subTitle(1, -1) + ">标准百分数</td>";
				}
				strResult[1] += "</tr>";

				for (i = 0; i < gcName.length; i = i + 2) {
					strResult[1] += "<tr>";
					for (j = 0; j < 2; j++) {
						strResult[1] += "<td" + subTitle(1, -1) + ">" + gvName[i + j] + "</td>" + "<td"
								+ subValue(1, -1) + ">" + map.get(geName[i + j] + "_o") + "</td>";
						if (i + j < gcName.length - 1) // 这里减一是因为“一致性”没有标准分
						{
							strResult[1] += "<td" + subValue(1, -1) + ">" + map.get(geName[i + j] + "_s") + "</td>";
						}
					}
					strResult[1] += "</tr>";
				}
				strResult[1] += "</table>";
			}

			// 指导意见
			String strCode = "";
			for (i = 0; i < gcName.length; i++) {
				if (map.get(geName[i] + "_d").toString().length() > 0) {
					strCode += map.get(geName[i] + "_d") + "|";
				}
			}
			if (strCode.length() > 0) {
				strCode = strCode.substring(0, strCode.length() - 1);
			}

			strResult[2] = strCode;

			strResult[3] = "0";
			strResult[4] = "";

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}

	}

	// 十、气质问卷Qizhi ☆
	private String[] GetQizhiReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "胆汁质,多血质,粘液质,抑郁质".split(",");
			String[] geName = "Dzz,Dxz,Nyz,Yyz".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(1, tWidth) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i] + "_o") + "</td></tr>";
				}
			}

			// 诊断结果
			int intCount = 0;
			for (i = 0; i < gcName.length; i++) {
				if (map.get(geName[i] + "_a").toString().length() > 0) {
					intCount += 1;
				}
			}

			// 要进行排序，将得分最高的放在前面
			String strAppraise = "";
			String strCode = "";

			if (intCount > 0) {
				float[] sngScoreA = new float[intCount];
				float[] sngCopyA = new float[intCount]; // 由于要进行两次排序

				String[] strScoreA = new String[intCount];
				String[] strCodeA = new String[intCount];

				intCount = 0;
				for (i = 0; i < gcName.length; i++) {
					if (map.get(geName[i] + "_a").toString().length() > 0) {
						sngScoreA[intCount] = Float.valueOf(map.get(geName[i] + "_o").toString())
								+ Float.valueOf(String.valueOf((4 - i) * 0.01));
						sngCopyA[intCount] = sngScoreA[intCount];

						strScoreA[intCount] = map.get(geName[i] + "_a").toString();
						strCodeA[intCount] = map.get(geName[i] + "_d").toString();
						intCount += 1;
					}
				}

				/*
				 * Array.Sort(sngScoreA, strScoreA) //排序，从小到大 Array.Sort(sngCopyA, strCodeA)
				 */

				// 下面这句是VB源码，功能是第一个数组按照从小到大排序，第二个数组，对应第一个的顺序同时调整位置。
				// Array.Sort(sngScoreA , strCodeA)
				// Array.Sort(sngCopyA, strCodeA)
				// 下面是对应上面这句话的功能进行JAVA改写

				Map<Float, String> mapTemp = new TreeMap<Float, String>(new Comparator<Float>() {
					public int compare(Float obj1, Float obj2) {
						// 降序排序
						return obj1.compareTo(obj2);
					}
				});
				for (i = 0; i < sngScoreA.length; i++) {
					mapTemp.put(sngScoreA[i], strScoreA[i]);
				}

				Set<Float> keySet = mapTemp.keySet();
				Iterator<Float> iter = keySet.iterator();
				while (iter.hasNext()) {
					Float key = iter.next();
					i = 0;
					sngScoreA[i] = key;
					strScoreA[i] = mapTemp.get(key);
					i += 1;
				}

				Map<Float, String> mapTemp2 = new TreeMap<Float, String>(new Comparator<Float>() {
					public int compare(Float obj1, Float obj2) {
						// 降序排序
						return obj1.compareTo(obj2);
					}
				});
				for (i = 0; i < sngCopyA.length; i++) {
					mapTemp2.put(sngCopyA[i], strCodeA[i]);
				}

				Set<Float> keySet2 = mapTemp2.keySet();
				Iterator<Float> iter2 = keySet2.iterator();
				while (iter2.hasNext()) {
					Float key = iter2.next();
					i = 0;
					sngCopyA[i] = key;
					strCodeA[i] = mapTemp2.get(key);
					i += 1;
				}

				// 从大到小
				for (i = 0; i < sngScoreA.length; i++) {
					strAppraise += strScoreA[i] + "-";
					strCode += strCodeA[i] + "|";
				}
			}
			if (strAppraise.length() > 0) {
				strAppraise = strAppraise.substring(0, strAppraise.length() - 1);
			}

			if (intCount == 4) {
				strAppraise = "四种混合型气质";
			}
			strResult[1] += "<tr><td" + subTitle(1, -1) + ">气质类型</td><td" + subValue(0, -1) + ">" + strAppraise
					+ "</td></tr>";

			strResult[1] += "</table>";

			if (strCode.length() > 0) {
				strCode = strCode.substring(0, strCode.length() - 1);
			}

			strResult[2] = strCode;

			strResult[3] = "0";
			strResult[4] = "";

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 十一、心理健康测查表Phi
	private String[] GetPhiReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "Ⅰ.躯体化,Ⅱ.抑郁,Ⅲ.焦虑,Ⅳ.病态人格,Ⅴ.疑心,Ⅵ.脱离现实,Ⅶ.兴奋状态,弃权的题数,说谎分,诈病或装坏".split(",");
			String[] gdName = "SOM,DEP,ANX,PSD,HYP,UNR,HMA,Q,L,F".split(",");
			String[] geName = "Som,Dep,Anx,Psd,Hyp,Unr,Hma,Q,Lie,F".toLowerCase().split(",");

			String[] gvName = {};
			switch (g_CorE) {
			case 1:
				gvName = gcName;
				break;
			case 2:
				gvName = gdName;
				break;
			}

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, oWidth * 3) + ">因子名称</td><td" + subTitle(0, tWidth)
						+ "></td><td" + subTitle(0, tWidth) + ">原始分</td>" + "<td" + subTitle(0, tWidth) + ">标准分</td><td"
						+ subTitle(0, -1) + "></td></tr>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, -1) + ">" + gvName[i] + "</td><td" + subTitle(0, -1) + ">"
							+ geName[i] + "</td><td" + subValue(0, -1) + ">" + map.get(geName[i] + "_o") + "</td>"
							+ "<td" + subValue(0, -1) + ">" + map.get(geName[i] + "_s") + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i] + "_a") + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			// 重新排列
			String[] strIdeaA = { "Q", "Lie", "F", "Som", "Dep", "Anx", "Psd", "Hyp", "Unr", "Hma", "Total" };
			String strCode = "";
			for (i = 0; i < strIdeaA.length; i++) {
				if (map.get(strIdeaA[i].toLowerCase() + "_d").toString().length() > 0) {
					strCode += map.get(strIdeaA[i].toLowerCase() + "_d") + "|";
				}
			}

			if (strCode.length() > 0) {
				strCode = strCode.substring(0, strCode.length() - 1);
			}

			strResult[2] = strCode;

			// 预警
			for (i = 0; i < gcName.length; i++) {
				if (map.get(geName[i] + "_a").equals("*") || map.get(geName[i] + "_a").equals("**")) {
					strResult[3] = "*";
					strResult[4] += gcName[i].toString() + "异常，";
				}
			}

			if (strResult[4].length() > 0) {
				strResult[4] = strResult[4].substring(0, strResult[4].length() - 1);
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 十二、90项症状清单Scl90(Scl90)
	// ---table_uuid: A6F2BDF7-F5D9-4310-8546-A5108E2136E1
	private String[] GetScl90Report(Map<String, Object> map, float vAge, String tenantType) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName1 = "总分,总均分,阴性项目数,阳性项目数,阳性项目平均分".split(",");
			String[] geName1 = "Total_o,Total_ave,Nst_o,Pst_o,Pst_ave".toLowerCase().split(",");
			String[] gsName1 = "129.96±38.76,1.44±0.43,65.08±18.33,24.92±18.41,2.60±0.59".split(",");

			String[] gcName2 = "躯体化,强迫症状,人际关系敏感,抑郁,焦虑,敌对,恐怖,偏执,精神病性,其他项目".split(",");
			String[] gdName2 = "SOM,O-C,I-S,DEP,ANX,HOS,PHOB,PAR,PSY,ADD".split(",");
			String[] geName2 = "Som,Obs,Int,Dep,Anx,Hos,Pno,Par,Psy,Other".toLowerCase().split(",");
			String[] gsName2; // =
								// "1.37±0.48,1.62±0.58,1.65±0.51,1.50±0.59,1.39±0.43,1.48±0.56,1.23±0.41,1.43±0.57,1.29±0.42,
								// ".split(","); //最后的“，”代表最后一个因子没有标准参考

			if (tenantType != null && ("prison".equals(tenantType) || "drug_controll".equals(tenantType)
					|| "hospital".equals(tenantType) || "judicial".equals(tenantType))) {
				gsName2 = "1.37±0.48,1.62±0.58,1.65±0.51,1.50±0.59,1.39±0.43,1.48±0.56,1.23±0.41,1.43±0.57,1.29±0.42, "
						.split(","); // 最后的“，”代表最后一个因子没有标准参考

			} else if (vAge >= 12f && vAge < 15f) // 初中常模
			{
				gsName2 = "1.50±0.50,1.90±0.59,1.77±0.61,1.67±0.60,1.62±0.58,1.79±0.69,1.49±0.55,1.66±0.59,1.56±0.53,1.65±0.58"
						.split(","); // 最后的“，”代表最后一个因子没有标准参考
			} else if (vAge >= 15f && vAge <= 18f) // 高中常模
			{
				gsName2 = "1.55±0.50,2.11±0.60,1.90±0.62,1.81±0.61,1.73±0.58,1.88±0.71,1.45±0.50,1.79±0.59,1.67±0.53,1.75±0.60"
						.split(","); // 最后的“，”代表最后一个因子没有标准参考
			} else // 全国常模
			{
				gsName2 = "1.42±0.44,1.66±0.52,1.51±0.49,1.50±0.47,1.34±0.39,1.49±0.51,1.27±0.39,1.44±0.47,1.33±0.39,1.45±0.45"
						.split(","); // 最后的“，”代表最后一个因子没有标准参考
			}

			String[] gvName2 = {};
			switch (g_CorE) {
			case 1:
				gvName2 = gcName2;
				break;
			case 2:
				gvName2 = gdName2;
				break;
			}

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, oWidth * 3) + "></td><td" + subTitle(0, tWidth) + ">原始分</td><td"
						+ subTitle(0, tWidth) + ">平均分</td>" + "<td" + subTitle(0, tWidth) + ">参考诊断</td><td"
						+ subTitle(0, -1) + ">均分±标准差</td></tr>";

				for (i = 0; i < gcName1.length; i++) {
					switch (i) {
					case 1:
					case 4:
						strResult[1] += "<tr><td" + subTitle(0, -1) + ">" + gcName1[i] + "</td><td></td><td"
								+ subValue(0, -1) + ">" + map.get(geName1[i]) + "</td>" + "<td></td><td"
								+ subValue(0, -1) + ">" + gsName1[i] + "</td></tr>";
						break;
					default:
						strResult[1] += "<tr><td" + subTitle(0, -1) + ">" + gcName1[i] + "</td><td" + subValue(0, -1)
								+ ">" + map.get(geName1[i]) + "</td>" + "<td></td><td></td><td" + subValue(0, -1) + ">"
								+ gsName1[i] + "</td></tr>";
						break;
					}
				}

				for (i = 0; i < gcName2.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, -1) + ">" + gvName2[i] + "</td><td" + subValue(0, -1) + ">"
							+ map.get(geName2[i] + "_o") + "</td>" + "<td" + subValue(0, -1) + ">"
							+ map.get(geName2[i] + "_ave") + "</td><td" + subValue(0, -1) + ">"
							+ map.get(geName2[i] + "_a") + "</td>" + "<td" + subValue(0, -1) + ">" + gsName2[i]
							+ "</td></tr>";
				}

				strResult[1] += "</table>";
			}

			String strCode = "";
			for (i = 0; i < geName2.length - 1; i++) {
				strCode += map.get(geName2[i] + "_d") + "|";
			}
			if (strCode.length() > 0) {
				strCode = strCode.substring(0, strCode.length() - 1);
			}

			strResult[2] = strCode;

			/*
			 * //预警 for (i = 0;i<gcName2.length;i++) { if (map.get(geName2[i] +
			 * "_a").equals("重") || map.get(geName2[i] + "_a").equals("极重")) { strResult[3]
			 * = "*"; strResult[4] += gcName2[i].toString() +
			 * String.valueOf(map.get(geName2[i] + "_a")) + "，"; } }
			 * 
			 * if (strResult[4].length() > 0) { strResult[4] =
			 * strResult[4].substring(0,strResult[4].length() - 1); } else { strResult[3] =
			 * "0"; strResult[4] = "正常"; }
			 */

			// 原先按照量表因子预警，目前按照量表总均分预警
			String[] strValueA = { "正常", "轻", "中", "重", "极重" };
			float[] sngValueA;

			if (tenantType != null && ("prison".equals(tenantType) || "drug_controll".equals(tenantType)
					|| "hospital".equals(tenantType) || "judicial".equals(tenantType))) {
				sngValueA = new float[] { 1.5f, 2.5f, 3.5f, 4.5f };
			} else if (vAge >= 12f && vAge < 15f) // 初中常模
			{
				sngValueA = new float[] { 2.08f, 2.48f, 2.82f, 3.21f };
			} else if (vAge >= 15f && vAge <= 18f) // 高中常模
			{
				sngValueA = new float[] { 2.18f, 2.58f, 2.92f, 3.31f };
			} else // 全国常模
			{
				sngValueA = new float[] { 1.76f, 2.06f, 2.31f, 2.6f };
			}

			strResult[3] = "4";
			strResult[4] = "极重";

			for (i = 0; i < sngValueA.length; i++) {
				if (Float.valueOf(String.valueOf(map.get("total_ave"))) <= sngValueA[i]) {
					strResult[3] = String.valueOf(i);
					strResult[4] = strValueA[i];
					break;
				}
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 十三、大学生心理健康调查表Upi，量表特殊，指导意见直接在内部生成，strResult[2]直接返回结果，而不是_d的字符串，需要在调用函数中做特殊判断
	// ---table_uuid: 68438330-E19F-46A1-A9AE-CB610D478D0B
	private String[] GetUpiReport(Map<String, Object> map, String vTable_uuid, String vAnswerString) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			// 以下报告内容需要重新排序，顺序如下（序号不显示）：
			// 1. 第25题做肯定选择者：显示题目 a2
			// 辅助题做肯定选择者：显示题目
			// 1. 至今为止，你感到在自身健康方面有问题吗? a6
			// 2. 曾经觉得心理卫生方面有问题吗? a7
			// 3. 至今为止，你曾经接受过心理卫生的咨询和治疗吗? a8
			// 明确提出咨询要求且属于心理问题者：显示想咨询的问题等
			// 明确想咨询的题号：显示想咨询的题号及题目内容
			// 8、16、26题做肯定选择者：显示题目 a3, a4, a5
			// UPI量表中的60道题目除5、20、35、50题外，另在除去25、8、16、26外余下52个题目中选择“是”的题目：显示题目（以下题目做肯定选择）

			int i = 0;
			String[] sAnswer;
			boolean blExist = false;

			strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<tr><td" + subTitle(0, -1) + ">总分：" + map.get("total_o") + "</td></tr>";
			}

			strResult[1] += "</table>";

			strResult[2] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";
			strResult[2] += "<tr><td" + subTitle(0, -1) + ">" + map.get("total_a1") + "</td></tr>";

			String strDetail = "";
			// 题25
			if (map.get("total_a2").toString().length() > 0) {
				strDetail += "<tr><td" + subTitle(0, -1) + ">" + tSpace + map.get("total_a2") + "</td></tr>";
			}
			// 辅助题
			for (i = 6; i < 9; i++) {
				if (map.get("total_a" + String.valueOf(i)).toString().length() > 0) {
					strDetail += "<tr><td" + subTitle(0, -1) + ">" + tSpace + map.get("total_a" + String.valueOf(i))
							+ "</td></tr>";
				}
			}

			// 特殊部分
			String[] strShowA;
			// String[] strAnswer = vAnswerString.split("@@");

			// ********************************************************************
			// 转换回原来格式
			String strTemp = vAnswerString.replaceAll("\\|@", "@@");
			// 临时赋值，JAVA默认切割时为空就不增加数组长度
			String[] strAnswer_c_Temp = strTemp.split("@@");
			String[] strAnswer = { "", "", "" };
			for (i = 0; i < strAnswer_c_Temp.length; i++) {
				strAnswer[i] = strAnswer_c_Temp[i].trim();
			}
			// ********************************************************************

			if (strAnswer.length == 3) {
				// “想要咨询的问题是”
				if (strAnswer[2].length() > 0) {
					strDetail += "<tr><td" + subTitle(0, -1) + ">" + tSpace + "想要咨询的问题是：" + "</td></tr>";
					strDetail += "<tr><td" + subValue(0, -1) + ">" + tSpace + tSpace + strAnswer[2] + "</td></tr>";
				}
				if (strAnswer[1].length() > 0) {
					// 显示在报告中
					// “想要咨询问题的题号是”
					blExist = false;
					sAnswer = strAnswer[1].split(",");
					strShowA = new String[sAnswer.length];

					for (i = 0; i < sAnswer.length; i++) {
						strShowA[i] = "";
						Pattern pattern = Pattern.compile("[0-9]*");
						if (pattern.matcher(sAnswer[i]).matches()) {
							if (Integer.valueOf(sAnswer[i]) >= 1 && Integer.valueOf(sAnswer[i]) <= 60) {
								strShowA[i] = String.valueOf(sAnswer[i]) + "、"
										+ getTableContentQuestion(vTable_uuid, Integer.valueOf(sAnswer[i]));
								blExist = true;
							}
						}
					}

					if (blExist) {
						strDetail += "<tr><td" + subTitle(0, -1) + ">" + tSpace + "想要咨询问题的题号是：" + "</td></tr>";
						for (i = 0; i < strShowA.length; i++) {
							if (strShowA[i].toString().length() > 0) {
								strDetail += "<tr><td" + subValue(0, -1) + ">" + tSpace + tSpace + strShowA[i]
										+ "</td></tr>";
							}
						}
					}
				}

				// 8,16,26题做肯定选择
				for (i = 3; i < 6; i++) {
					if (map.get("total_a" + i).toString().length() > 0) {
						strDetail += "<tr><td" + subTitle(0, -1) + ">" + tSpace + map.get("total_a" + String.valueOf(i))
								+ "</td></tr>";
					}
				}

				// 最后才把所有内容赋值
				if (strDetail.length() > 0) {
					strResult[2] += "<tr><td" + subTitle(0, -1) + ">" + "详情如下：</td></tr>" + strDetail;
				}

				strResult[2] += "</table>";

			}

			// 预警
			if (map.get("total_a1").equals("第一类结果：有明显的心理问题，请尽快到咨询机构面谈！")) {
				strResult[3] = "4";
				strResult[4] = "第一类结果：有明显的心理问题，请尽快到咨询机构面谈！";
			} else if (map.get("total_a1").equals("第二类结果：可能有心理问题，应该引起关注！")) {
				strResult[3] = "3";
				strResult[4] = "第二类结果：可能有心理问题,应该引起关注！";
			} else {
				strResult[3] = "0";
				strResult[4] = "第三类结果：心理健康！";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 十四、一般健康问卷Ghq CE
	private String[] GetGhqReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "生理健康,精神心理健康,社会活动与工作能力,生活态度及前途".split(",");
			String[] gdName = "A,B,C,D".split(",");
			String[] geName = "Sljk,Jsxl,Shhd,Shtd".toLowerCase().split(",");

			String[] gvName = {};
			switch (g_CorE) {
			case 1:
				gvName = gcName;
				break;
			case 2:
				gvName = gdName;
				break;
			}

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth * 2) + ">" + gvName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i] + "_o") + "(" + map.get(geName[i] + "_a") + ")</td></tr>";
				}

				strResult[1] += "<tr><td" + subTitle(0, -1) + ">总分</td><td" + subValue(0, -1) + ">" + map.get("total_o")
						+ "</td></tr>";
				strResult[1] += "<tr><td" + subTitle(0, -1) + ">诊断结果</td><td" + subValue(0, -1) + ">"
						+ map.get("total_a") + "</td></tr>";

				strResult[1] += "</table>";
			}

			// 预警
			if (map.get("total_a").equals("健康")) {
				strResult[3] = "0";
				strResult[4] = "健康";
			} else if (map.get("total_a").equals("基本健康")) {
				strResult[3] = "1";
				strResult[4] = "基本健康";
			} else if (map.get("total_a").equals("有健康问题")) {
				strResult[3] = "2";
				strResult[4] = "有健康问题";
			} else if (map.get("total_a").equals("有严重健康问题")) {
				strResult[3] = "3";
				strResult[4] = "有严重健康问题";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 十五、十六、康奈尔医学指数(男)(女)Cmi
	private String[] GetCmiReport(Map<String, Object> map, int gender) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i, j;
			String[] gcName = "眼和耳,呼吸系统,心血管系统,消化系统,肌肉骨骼系统,皮肤,神经系统,生殖泌尿系统,疲劳感,既往健康状况,既往病史,习惯,不适应,抑郁,焦虑,敏感,愤怒,紧张"
					.split(",");
			String[] gdName = "A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R".split(",");
			String[] geName = "Yhe,Hxxt,Xxgxt,Xhxt,Jrgg,Pf,Sjxt,Szmn,Plg,Jwjk,Jwbs,Xg,Bsy,Yy,Jl,Mg,Fn,Jz".toLowerCase()
					.split(",");
			String[] gsName = "9,18,13,23,8,7,18,11,7,9,15,6,12,6,9,6,9,9".split(",");
			String[] strSeA = new String[2];

			String[] gvName = {};
			switch (g_CorE) {
			case 1:
				gvName = gcName;
				break;
			case 2:
				gvName = gdName;
				break;
			}

			if (g_inblFactor) // 因子得分
			{
				if (gender == 1) {
					strSeA[0] = "参考筛查界值≥35分";
					strSeA[1] = "参考筛查界值≥15分";
				} else {
					strSeA[0] = "参考筛查界值≥40分";
					strSeA[1] = "参考筛查界值≥20分";
				}

				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, -1) + ">总分</td><td" + subValue(0, -1) + ">" + map.get("total_o")
						+ "</td><td colspan='4'" + subValue(0, -1) + ">" + strSeA[0] + "</td></tr>";
				strResult[1] += "<tr><td" + subTitle(0, -1) + ">M-R分值</td><td" + subValue(0, -1) + ">" + map.get("mr_o")
						+ "</td><td colspan='4'" + subValue(0, -1) + ">" + strSeA[1] + "</td></tr>";
				strResult[1] += "<tr><td colspan='6'" + subTitle(0, -1) + ">各项分指标得分：</td></tr>";

				for (i = 0; i < gcName.length; i = i + 2) {
					strResult[1] += "<tr>";
					for (j = 0; j < 2; j++) {
						strResult[1] += "<td" + subTitle(0, tWidth + oWidth) + ">" + gvName[i + j] + "</td><td"
								+ subValue(0, oWidth) + ">" + map.get(geName[i + j] + "_o") + "</td><td"
								+ subValue(0, tWidth) + ">(满分" + gsName[i + j] + "分)</td>";
					}
					strResult[1] += "</tr>";
				}
				strResult[1] += "</table>";
			}

			strResult[3] = "0";
			strResult[4] = "";

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 十七、抑郁自评量表Sds ☆ “重点提示”
	// ---table_uuid: 37404F75-7DC3-4EDF-AF04-3C2D5723AF67
	private String[] GetSdsReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "总粗分,标准总分,参考诊断".split(",");
			String[] geName = "Total_o,Total_s,Total_a".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i]) + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			if (map.get("total_a").equals("无抑郁症状")) {
				strResult[3] = "0";
				strResult[4] = "无抑郁症状";
			} else if (map.get("total_a").equals("有（轻度）抑郁症状")) {
				strResult[3] = "1";
				strResult[4] = "有（轻度）抑郁症状";
			} else if (map.get("total_a").equals("有（中度）抑郁症状")) {
				strResult[3] = "2";
				strResult[4] = "有（中度）抑郁症状";
			} else if (map.get("total_a").equals("有（重度）抑郁症状")) {
				strResult[3] = "3";
				strResult[4] = "有（重度）抑郁症状";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 十八、汉密顿抑郁量表Hamd
	private String[] GetHamdReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "总粗分,焦虑/躯体化,体重,认识障碍,日夜变化,阻滞,睡眠障碍,绝望感,全身症状".split(",");
			String[] geName = "Total,Jl,Tz,Rsza,Rybh,Zz,Smza,Jwg,Qszz".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, oWidth * 3) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i] + "_o") + "</td></tr>";
				}

				strResult[1] += "<tr><td" + subTitle(0, -1) + ">诊断结果</td><td" + subValue(0, -1) + ">"
						+ map.get("total_a") + "</td></tr>";

				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			if (map.get("total_a").equals("没有抑郁症状")) {
				strResult[3] = "0";
				strResult[4] = "没有抑郁症状";
			} else if (map.get("total_a").equals("可能有抑郁症状")) {
				strResult[3] = "1";
				strResult[4] = "可能有抑郁症状";
			} else if (map.get("total_a").equals("可能有中度的抑郁症状")) {
				strResult[3] = "2";
				strResult[4] = "可能有中度的抑郁症状";
			} else if (map.get("total_a").equals("可能有严重抑郁症状")) {
				strResult[3] = "3";
				strResult[4] = "可能有严重抑郁症状";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 十九、BECK抑郁问卷Bdi
	private String[] GetBdiReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "总分,诊断结果".split(",");
			String[] geName = "Total_o,Total_a".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i]) + "</td></tr>";
				}

				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			if (map.get("total_a").equals("无抑郁或极轻度")) {
				strResult[3] = "0";
				strResult[4] = "无抑郁或极轻度";
			} else if (map.get("total_a").equals("轻度")) {
				strResult[3] = "1";
				strResult[4] = "轻度";
			} else if (map.get("total_a").equals("中度")) {
				strResult[3] = "2";
				strResult[4] = "中度";
			} else if (map.get("total_a").equals("重度")) {
				strResult[3] = "3";
				strResult[4] = "重度";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 二十、流调用抑郁自评量表Ces
	private String[] GetCesReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "总分,诊断结果".split(",");
			String[] geName = "Total_o,Total_a".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i]) + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			if (map.get("total_a").equals("无抑郁症状")) {
				strResult[3] = "0";
				strResult[4] = "无抑郁症状";
			} else if (map.get("total_a").equals("可能有抑郁症状")) {
				strResult[3] = "1";
				strResult[4] = "可能有抑郁症状";
			} else if (map.get("total_a").equals("有抑郁症状")) {
				strResult[3] = "2";
				strResult[4] = "有抑郁症状";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 二十一、纽卡斯尔抑郁诊断量表Ndi
	private String[] GetNdiReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "总分,诊断结果".split(",");
			String[] geName = "Total_o,Total_a".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i]) + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			if (map.get("total_a").equals("为可疑内因性忧郁症")) {
				strResult[3] = "1";
				strResult[4] = "为可疑内因性忧郁症";
			} else if (map.get("total_a").equals("内因性忧郁症")) {
				strResult[3] = "2";
				strResult[4] = "内因性忧郁症";
			} else if (map.get("total_a").equals("可考虑为抑郁性神经症")) {
				strResult[3] = "3";
				strResult[4] = "可考虑为抑郁性神经症";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 二十二、焦虑自评量表Sas
	// ---table_uuid: 7111F968-61BB-4573-8FB8-5F10F8BF75EB
	private String[] GetSasReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "总粗分,标准总分,诊断结果".split(",");
			String[] geName = "Total_o,Total_s,Total_a".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i]) + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			if (map.get("total_a").equals("无焦虑症状")) {
				strResult[3] = "0";
				strResult[4] = "无焦虑症状";
			} else if (map.get("total_a").equals("有（轻度）焦虑症状")) {
				strResult[3] = "1";
				strResult[4] = "有（轻度）焦虑症状";
			} else if (map.get("total_a").equals("有（中度）焦虑症状")) {
				strResult[3] = "2";
				strResult[4] = "有（中度）焦虑症状";
			} else if (map.get("total_a").equals("有（重度）焦虑症状")) {
				strResult[3] = "3";
				strResult[4] = "有（重度）焦虑症状";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 二十三、焦虑状态询问表Stai1
	private String[] GetStai1Report(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "总分,诊断结果".split(",");
			String[] geName = "Total_o,Total_a".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i]) + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			if (map.get("total_a").equals("目前无焦虑状态")) {
				strResult[3] = "0";
				strResult[4] = "目前无焦虑状态";
			} else if (map.get("total_a").equals("目前处于（轻度）焦虑状态")) {
				strResult[3] = "1";
				strResult[4] = "目前处于（轻度）焦虑状态";
			} else if (map.get("total_a").equals("目前处于（中度）焦虑状态")) {
				strResult[3] = "2";
				strResult[4] = "目前处于（中度）焦虑状态";
			} else if (map.get("total_a").equals("目前处于（重度）焦虑状态")) {
				strResult[3] = "3";
				strResult[4] = "目前处于（重度）焦虑状态";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 二十四、焦虑习性调查Stai2
	private String[] GetStai2Report(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "总分,诊断结果".split(",");
			String[] geName = "Total_o,Total_a".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i]) + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			// 预警
			if (map.get("total_a").equals("通常无焦虑特质")) {
				strResult[3] = "0";
				strResult[4] = "通常无焦虑特质";
			} else if (map.get("total_a").equals("通常有（轻度）焦虑特质")) {
				strResult[3] = "1";
				strResult[4] = "通常有（轻度）焦虑特质";
			} else if (map.get("total_a").equals("通常有（中度）焦虑特质")) {
				strResult[3] = "2";
				strResult[4] = "通常有（中度）焦虑特质";
			} else if (map.get("total_a").equals("通常有（重度）焦虑特质")) {
				strResult[3] = "3";
				strResult[4] = "通常有（重度）焦虑特质";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 二十五、汉密顿焦虑量表Hama
	private String[] GetHamaReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "总分,躯体化焦虑,精神性焦虑,诊断结果".split(",");
			String[] gdName = "总分,SOM,PSY,诊断结果".split(",");
			String[] geName = "Total_o,Qth_o,Jsh_o,Total_a".toLowerCase().split(",");

			String[] gvName = {};
			switch (g_CorE) {
			case 1:
				gvName = gcName;
				break;
			case 2:
				gvName = gdName;
				break;
			}

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gvName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i]) + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			if (map.get("total_a").equals("没有焦虑症状")) {
				strResult[3] = "0";
				strResult[4] = "没有焦虑症状";
			} else if (map.get("total_a").equals("可能有焦虑症状")) {
				strResult[3] = "1";
				strResult[4] = "可能有焦虑症状";
			} else if (map.get("total_a").equals("肯定有焦虑症状")) {
				strResult[3] = "2";
				strResult[4] = "肯定有焦虑症状";
			} else if (map.get("total_a").equals("可能有明显焦虑症状")) {
				strResult[3] = "3";
				strResult[4] = "可能有明显焦虑症状";
			} else if (map.get("total_a").equals("可能有严重焦虑症状")) {
				strResult[3] = "4";
				strResult[4] = "可能有严重焦虑症状";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 二十六、贝克焦虑量表Bai
	private String[] GetBaiReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "粗分,标准分,诊断结果".split(",");
			String[] geName = "Total_o,Total_s,Total_a".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i]) + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			if (map.get("total_a").equals("无焦虑症状")) {
				strResult[3] = "0";
				strResult[4] = "无焦虑症状";
			} else if (map.get("total_a").equals("有焦虑症状")) {
				strResult[3] = "1";
				strResult[4] = "有焦虑症状";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 二十七、社交焦虑量表Lsas
	private String[] GetLsasReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "害怕/焦虑总分,回避总分,合计总分,参考诊断".split(",");
			String[] geName = "Hp_o,Hb_o,Total_o,Total_a".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, oWidth * 3) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i]) + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			if (map.get("total_a").equals("正常")) {
				strResult[3] = "0";
				strResult[4] = "正常";
			} else if (map.get("total_a").equals("有社交焦虑")) {
				strResult[3] = "1";
				strResult[4] = "有社交焦虑";
			} else if (map.get("total_a").equals("有较严重的社交焦虑障碍")) {
				strResult[3] = "2";
				strResult[4] = "有较严重的社交焦虑障碍";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 二十八、惧怕否定评价量表Fne
	private String[] GetFneReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "总分,诊断结果".split(",");
			String[] geName = "Total_o,Total_a".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName[i] + "</td><td" + subValue(0, -1) + ">"
						+ map.get(geName[i]) + "</td></tr>";

				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			if (map.get("total_a").equals("正常范围")) {
				strResult[3] = "0";
				strResult[4] = "正常范围";
			} else if (map.get("total_a").equals("轻度惧怕否定")) {
				strResult[3] = "1";
				strResult[4] = "轻度惧怕否定";
			} else if (map.get("total_a").equals("中度惧怕否定")) {
				strResult[3] = "2";
				strResult[4] = "中度惧怕否定";
			} else if (map.get("total_a").equals("重度惧怕否定")) {
				strResult[3] = "3";
				strResult[4] = "重度惧怕否定";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 二十九、艾森克情绪稳定性测验Ask
	private String[] GetAskReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i, j;
			String[] gcName = "自卑感,抑郁性,焦虑,强迫状态,自主性,疑病,负罪感".split(",");
			String[] geName = "Zbg,Yyx,Jl,Qbzt,Zzx,Yxb,Fzg".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i = i + 3) {
					strResult[1] += "<tr>";
					for (j = 0; j < 3; j++) {
						if (i + j > gcName.length - 1) {
							break;
						}
						strResult[1] += "<td" + subTitle(0, tWidth) + ">" + gcName[i + j] + "</td><td"
								+ subValue(0, tWidth) + ">" + map.get(geName[i + j] + "_o") + "</td>";
					}
					strResult[1] += "</tr>";
				}
				strResult[1] += "</table>";
			}

			String strCode = "";
			for (i = 0; i < gcName.length; i++) {
				strCode += map.get(geName[i] + "_d") + "|";
			}
			if (strCode.length() > 0) {
				strCode = strCode.substring(0, strCode.length() - 1);
			}

			strResult[2] = strCode;

			for (i = 0; i < gcName.length; i++) {
				switch (i) {
				case 0:
					switch (String.valueOf(map.get(geName[i] + "_d")).split("\\.")[2]) {
					case "1":
						strResult[3] = "*";
						strResult[4] += "严重自卑" + "，";
						break;
					case "2":
						strResult[3] = "*";
						strResult[4] += "比较自卑" + "，";
						break;
					case "3":
						strResult[3] = "*";
						strResult[4] += "有自卑感" + "，";
						break;
					}
					break;
				case 1:
					switch (String.valueOf(map.get(geName[i] + "_d")).split("\\.")[2]) {
					case "1":
						strResult[3] = "*";
						strResult[4] += "严重抑郁" + "，";
						break;
					case "2":
						strResult[3] = "*";
						strResult[4] += "中度抑郁" + "，";
						break;
					case "3":
						strResult[3] = "*";
						strResult[4] += "轻度抑郁" + "，";
						break;
					}
					break;
				case 2:
					switch (String.valueOf(map.get(geName[i] + "_d")).split("\\.")[2]) {
					case "3":
						strResult[3] = "*";
						strResult[4] += "轻度焦虑" + "，";
						break;
					case "4":
						strResult[3] = "*";
						strResult[4] += "中度焦虑" + "，";
						break;
					case "5":
						strResult[3] = "*";
						strResult[4] += "重度焦虑" + "，";
						break;
					}
					break;
				case 3:
					switch (String.valueOf(map.get(geName[i] + "_d")).split("\\.")[2]) {
					case "3":
						strResult[3] = "*";
						strResult[4] += "轻度强迫症状" + "，";
						break;
					case "4":
						strResult[3] = "*";
						strResult[4] += "中度强迫症状" + "，";
						break;
					case "5":
						strResult[3] = "*";
						strResult[4] += "重度强迫症状" + "，";
						break;
					}
					break;
				case 4:
					switch (String.valueOf(map.get(geName[i] + "_d")).split("\\.")[2]) {
					case "1":
						strResult[3] = "*";
						strResult[4] += "严重依赖" + "，";
						break;
					case "2":
						strResult[3] = "*";
						strResult[4] += "比较依赖" + "，";
						break;
					case "3":
						strResult[3] = "*";
						strResult[4] += "比较依赖" + "，";
						break;
					}
					break;
				case 5:
					switch (String.valueOf(map.get(geName[i] + "_d")).split("\\.")[2]) {
					case "3":
						strResult[3] = "*";
						strResult[4] += "轻度疑心病" + "，";
						break;
					case "4":
						strResult[3] = "*";
						strResult[4] += "中度疑心病" + "，";
						break;
					case "5":
						strResult[3] = "*";
						strResult[4] += "重度疑心病" + "，";
						break;
					}
					break;
				case 6:
					switch (String.valueOf(map.get(geName[i] + "_d")).split("\\.")[2]) {
					case "3":
						strResult[3] = "*";
						strResult[4] += "轻度负罪感" + "，";
						break;
					case "4":
						strResult[3] = "*";
						strResult[4] += "中度负罪感" + "，";
						break;
					case "5":
						strResult[3] = "*";
						strResult[4] += "重度负罪感" + "，";
						break;
					}
					break;
				}
				// switch (String.valueOf(map.get(geName[i] + "_d")).split(".")[2])
				// if (map.get(geName[i] + "_d").equals(""))
			}

			if (strResult[4].length() > 0) {
				strResult[4] = strResult[4].substring(0, strResult[4].length() - 1);
			} else {
				strResult[3] = "0";
				strResult[4] += "正常";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 三十、社交回避及苦恼量表Sad
	private String[] GetSadReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			String gcName = "总分";
			String geName = "Total_o".toLowerCase();

			if (g_inblFactor) {
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName + "</td><td" + subValue(0, -1) + ">"
						+ map.get(geName) + "</td></tr>";

				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			switch (String.valueOf(map.get("total_d")).split("\\.")[2]) {
			case "1":
				strResult[3] = "0";
				strResult[4] = "正常";
				break;
			case "2":
				strResult[3] = "1";
				strResult[4] = "轻度";
				break;
			case "3":
				strResult[3] = "2";
				strResult[4] = "中度";
				break;
			case "4":
				strResult[3] = "3";
				strResult[4] = "重度";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 三十一、情绪--社交孤独问卷Esli
	private String[] GetEsliReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i;
			String[] gcName = "情绪孤立,社交孤立,情绪孤独,社交孤独".split(",");
			String[] geName = "Qxgl,Sjgl,Qxgd,Sjgd".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i] + "_o") + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			String strCode = "";
			for (i = 0; i < gcName.length; i++) {
				strCode += map.get(geName[i] + "_d") + "|";
			}
			if (strCode.length() > 0) {
				strCode = strCode.substring(0, strCode.length() - 1);
			}

			strResult[2] = strCode;

			for (i = 0; i < strCode.split("\\|").length; i++) {
				if (String.valueOf(strCode.split("\\|")[i]).split("\\.")[2].equals("4")) {
					strResult[3] = "*";
					strResult[4] += gcName[i].toString() + "问题严重" + "，";
				}
			}

			if (strResult[4].length() > 0) {
				strResult[4] = strResult[4].substring(0, strResult[4].length() - 1);
			} else {
				strResult[3] = "0";
				strResult[4] += "正常";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 三十二、医院焦虑抑郁量表Hads
	private String[] GetHadsReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "焦虑总分,抑郁总分".split(",");
			String[] geName = "Jl,Yy".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName[i] + "</td><td" + subValue(0, tWidth)
							+ ">" + map.get(geName[i] + "_o") + "</td><td" + subValue(0, -1) + ">"
							+ map.get(geName[i] + "_a") + "</td></tr>";

				}
				strResult[1] += "<tr><td" + subTitle(0, -1) + ">总分</td><td colspan='2'" + subValue(0, -1) + ">"
						+ map.get("total_o") + "</td></tr>";

				strResult[1] += "</table>";
			}

			for (i = 0; i < gcName.length; i++) {
				if (String.valueOf(map.get(geName[i] + "_a")).equals("有焦虑症状")) {
					strResult[3] = "*";
					strResult[4] += "有焦虑症状" + "，";
				}
				if (String.valueOf(map.get(geName[i] + "_a")).equals("有抑郁症状")) {
					strResult[3] = "*";
					strResult[4] += "有抑郁症状" + "，";
				}
			}

			if (strResult[4].length() > 0) {
				strResult[4] = strResult[4].substring(0, strResult[4].length() - 1);
			} else {
				strResult[3] = "0";
				strResult[4] += "正常";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 三十三、精神状态全面量表Cprs
	private String[] GetCprsReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "总分,精神分裂症分量表总分,抑郁症分量表总分".split(",");
			String[] geName = "Total,Jsfl,Yyz".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth * 2) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i] + "_o") + "</td></tr>";

				}
				strResult[1] += "</table>";
			}

			strResult[3] = "0";
			strResult[4] = "";

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 三十四、简明精神病量表Bprs
	private String[] GetBprsReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "焦虑忧郁,缺乏活力,思维障碍,激活性,敌对猜疑".split(",");
			String[] geName = "Jlyy,Qfhl,Swza,Jhx,Ddcy".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, -1) + ">总粗分</td><td" + subValue(0, -1) + ">"
						+ map.get("total_o") + "</td></tr>";
				strResult[1] += "<tr><td" + subTitle(0, tWidth) + "></td><td" + subTitle(0, tWidth) + ">因子分</td><td"
						+ subTitle(0, tWidth) + ">平均分</td><td" + subTitle(0, tWidth) + ">参考提示</td></tr>";
				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, -1) + ">" + gcName[i] + "</td><td" + subValue(0, -1) + ">"
							+ map.get(geName[i] + "_o") + "</td>" + "<td" + subValue(0, -1) + ">"
							+ map.get(geName[i] + "_ave") + "</td><td" + subValue(0, -1) + ">"
							+ map.get(geName[i] + "_a") + "</td></tr>";
				}

				strResult[1] += "</table>";
			}

			for (i = 0; i < gcName.length; i++) {
				if (map.get(geName[i] + "_a").equals("极重")) {
					strResult[3] = "*";
					strResult[4] += gcName[i].toString() + "极重" + "，";
				} else if (map.get(geName[i] + "_a").equals("重度")) {
					strResult[3] = "*";
					strResult[4] += gcName[i].toString() + "重度" + "，";
				} else if (map.get(geName[i] + "_a").equals("偏重")) {
					strResult[3] = "*";
					strResult[4] += gcName[i].toString() + "偏重" + "，";
				} else if (map.get(geName[i] + "_a").equals("中度")) {
					strResult[3] = "*";
					strResult[4] += gcName[i].toString() + "中度" + "，";
				} else if (map.get(geName[i] + "_a").equals("轻度")) {
					strResult[3] = "*";
					strResult[4] += gcName[i].toString() + "轻度" + "，";
				}
			}

			if (strResult[4].length() > 0) {
				strResult[4] = strResult[4].substring(0, strResult[4].length() - 1);
			} else {
				strResult[3] = "0";
				strResult[4] += "正常";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 三十五、躁狂量表Brms
	private String[] GetBrmsReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "总分,幻觉,妄想,诊断结果".split(",");
			String[] geName = "Total_o,Hj_o,Wx_o,Total_a".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i]) + "</td></tr>";
				}

				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			switch (String.valueOf(map.get("total_a"))) {
			case "无明显躁狂症状":
				strResult[3] = "0";
				strResult[4] = "无明显躁狂症状";
				break;
			case "有躁狂症状":
				strResult[3] = "1";
				strResult[4] = "有躁狂症状";
				break;
			case "有一定严重程度的躁狂症状":
				strResult[3] = "2";
				strResult[4] = "有一定严重程度的躁狂症状";
				break;
			case "有严重的躁狂症状":
				strResult[3] = "3";
				strResult[4] = "有严重的躁狂症状";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 三十六、阴性症状量表Sans
	private String[] GetSansReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "总分,分量表综合评价总分,情形平淡或迟钝综合评价,思维贫乏综合评价,意志缺乏综合评价,兴趣/社交缺乏综合评价,注意障碍综合评价,突出的阴性症状群".split(",");
			String[] geName = "Total_o,Flb_o,Qxpd_o,Swpf_o,Yzqf_o,Xq_o,Zyza_o,Tcyx_a".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, oWidth * 5) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i]) + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			if (String.valueOf(map.get("total_d")).equals("")) {
				strResult[3] = "0";
				strResult[4] = "正常";
			} else {
				switch (String.valueOf(map.get("total_d")).split("\\.")[2]) {
				case "1":
					strResult[3] = "1";
					strResult[4] = "轻度";
					break;
				case "2":
					strResult[3] = "2";
					strResult[4] = "中度";
					break;
				case "3":
					strResult[3] = "3";
					strResult[4] = "重度";
					break;
				}
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 三十七、阳性症状量表Saps
	private String[] GetSapsReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "总分,分量表综合评价总分,幻觉综合评价,妄想综合评价,怪异行为综合评价,阳性思维形式障碍综合评价,突出的阳性症状群".split(",");
			String[] geName = "Total_o,Flb_o,Hj_o,Wx_o,Gyxw_o,Yxsw_o,Tcyx_a".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, oWidth * 5) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i]) + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			if (String.valueOf(map.get("total_d")).equals("")) {
				strResult[3] = "0";
				strResult[4] = "正常";
			} else {
				switch (String.valueOf(map.get("total_d")).split("\\.")[2]) {
				case "1":
					strResult[3] = "1";
					strResult[4] = "轻度";
					break;
				case "2":
					strResult[3] = "2";
					strResult[4] = "中度";
					break;
				case "3":
					strResult[3] = "3";
					strResult[4] = "重度";
					break;
				}
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 三十八、副反应量表Tess
	private String[] GetTessReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName1 = "行为毒性,化验异常,神经系,植物神经系统,心血管系,其他,总分".split(",");
			String[] geName1 = "Xwdx,Hyyc,Sjx,Zwsj,Xxg,Other,Total".toLowerCase().split(",");
			String[] gsName1 = "_yz_o,_yz_ave,_cl_o,_cl_ave".split(",");

			String[] gcName2 = "第34题,第35题,严重程度总评,痛苦程度总评".split(",");
			String[] geName2 = "Answer34,Answer35,Yzcd,Tkcd".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">严重程度</td><td" + subTitle(0, tWidth) + ">原始分</td><td"
						+ subTitle(0, tWidth) + ">均分</td>" + "<td" + subTitle(0, tWidth) + ">处理</td><td"
						+ subTitle(0, tWidth) + ">原始分</td><td" + subTitle(0, -1) + ">均分</td></tr>";
				for (i = 0; i < gcName1.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, -1) + ">" + gcName1[i] + "</td><td" + subValue(0, -1) + ">"
							+ map.get(geName1[i] + gsName1[0]) + "</td>" + "<td" + subValue(0, -1) + ">"
							+ map.get(geName1[i] + gsName1[1]) + "</td><td" + subTitle(0, -1) + ">" + gcName1[i]
							+ "</td>" + "<td" + subValue(0, -1) + ">" + map.get(geName1[i] + gsName1[2]) + "</td><td"
							+ subValue(0, -1) + ">" + map.get(geName1[i] + gsName1[3]) + "</td></tr>";
				}
				for (i = 0; i < gcName2.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, -1) + ">" + gcName2[i] + "</td><td colspan='5'"
							+ subValue(0, -1) + ">" + map.get(geName2[i] + "_a") + "</td></tr>";
				}

				strResult[1] += "</table>";
			}

			int intResult1 = 0;
			int intResult2 = 0;
			switch (String.valueOf(map.get("yzcd_a"))) {
			case "无":
				intResult1 = 0;
				strResult[4] += "";
				break;
			case "轻":
				intResult1 = 1;
				strResult[4] += "严重程度总评轻度" + "，";
				break;
			case "中":
				intResult1 = 2;
				strResult[4] += "严重程度总评中度" + "，";
				break;
			case "重":
				intResult1 = 3;
				strResult[4] += "严重程度总评重度" + "，";
				break;
			}

			switch (String.valueOf(map.get("tkcd_a"))) {
			case "无":
				intResult2 = 0;
				strResult[4] += "";
				break;
			case "轻":
				intResult2 = 1;
				strResult[4] += "痛苦程度总评轻度" + "，";
				break;
			case "中":
				intResult2 = 2;
				strResult[4] += "痛苦程度总评中度" + "，";
				break;
			case "重":
				intResult2 = 3;
				strResult[4] += "痛苦程度总评重度" + "，";
				break;
			}

			if (intResult1 > intResult2) {
				strResult[3] = String.valueOf(intResult1);
			} else {
				strResult[3] = String.valueOf(intResult2);
			}

			if (strResult[4].length() > 0) {
				strResult[4] = strResult[4].substring(0, strResult[4].length() - 1);
			} else {
				strResult[3] = "0";
				strResult[4] = "正常";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 三十九、抗抑郁药副反应量表Sers
	private String[] GetSersReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "身体疲倦,头痛,睡眠障碍,头晕,直立性虚脱,心悸,震颤,出汗,口干,便秘,排尿障碍,嗜睡,性功能障碍,其他症状".split(",");
			String[] geName = "Stpj,Tt,Smza,Ty,Zlxxt,Xj,Zc,Ch,Kg,Bm,Pnza,Ss,Xgnza,Qtzz".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i = i + 2) {
					strResult[1] += "<tr><td" + subTitle(0, oWidth * 3) + ">" + gcName[i] + "</td><td"
							+ subValue(0, tWidth) + ">" + map.get(geName[i] + "_a") + "</td>" + "<td"
							+ subTitle(0, oWidth * 3) + ">" + gcName[i + 1] + "</td><td" + subValue(0, -1) + ">"
							+ map.get(geName[i + 1] + "_a") + "</td></tr>";
				}
				strResult[1] += "<tr><td" + subTitle(0, -1) + ">总分</td><td" + subValue(0, -1) + ">" + map.get("total_o")
						+ "</td></tr>";

				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			if (String.valueOf(map.get("total_d")).equals("")) {
				strResult[3] = "0";
				strResult[4] = "正常";
			} else {
				switch (String.valueOf(map.get("total_d")).split("\\.")[2]) {
				case "1":
					strResult[3] = "1";
					strResult[4] = "轻度";
					break;
				case "2":
					strResult[3] = "2";
					strResult[4] = "中度";
					break;
				case "3":
					strResult[3] = "3";
					strResult[4] = "重度";
					break;
				}
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 四十、锥体外系副反应量表Reses
	private String[] GetResesReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			String gcName = "总分";
			String geName = "Total_o".toLowerCase();
			if (g_inblFactor) {
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName + "</td><td" + subValue(0, -1) + ">"
						+ map.get(geName) + "</td></tr>";

				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			if (String.valueOf(map.get("total_d")).equals("")) {
				strResult[3] = "0";
				strResult[4] = "正常";
			} else {
				switch (String.valueOf(map.get("total_d")).split("\\.")[2]) {
				case "1":
					strResult[3] = "1";
					strResult[4] = "轻度";
					break;
				case "2":
					strResult[3] = "2";
					strResult[4] = "中度";
					break;
				case "3":
					strResult[3] = "3";
					strResult[4] = "重度";
					break;
				}
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 四十一、日常生活能力量表Adl
	private String[] GetAdlReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "总分,躯体生活自理,工具性日常生活能力,诊断结果".split(",");
			String[] geName = "Total_o,Qtsh_o,Gjx_o,Total_a".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth * 2) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i]) + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			switch (String.valueOf(map.get("total_a"))) {
			case "无功能障碍":
				strResult[3] = "0";
				strResult[4] = "无功能障碍";
				break;
			case "功能有一定程度的下降":
				strResult[3] = "1";
				strResult[4] = "功能有一定程度的下降";
				break;
			case "明显功能障碍":
				strResult[3] = "2";
				strResult[4] = "明显功能障碍";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 四十二、社会功能缺陷量表Sdss
	private String[] GetSdssReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "总分,1.职业和工作,2.婚姻职能,3.父母职能,4.社会性退缩,5.家庭外的社会活动,6.家庭内的社会活动,7.家庭职能,8.个人生活自理,9.对外界的兴趣和关心,10.责任心和计划性,诊断"
					.split(",");
			String[] geName = "Total_o,Zyhgz_a,Hyzn_a,Fmzn_a,Shx_a,Jtw_a,Jtn_a,Jtzn_a,Grsh_a,Dwj_a,Zrx_a,Total_a"
					.toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth * 2) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i]) + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			switch (String.valueOf(map.get("total_a"))) {
			case "正常":
				strResult[3] = "0";
				strResult[4] = "正常";
				break;
			case "有社会功能缺陷":
				strResult[3] = "1";
				strResult[4] = "有社会功能缺陷";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 四十三、Yale-Brown强迫评定量表YaleBrown
	private String[] GetYaleBrownReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "强迫思维计分,强迫行为计分,总分".split(",");
			String[] geName = "Qpsw,Qpxw,Total".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth * 2) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i] + "_o") + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			switch (String.valueOf(map.get("total_d")).split("\\.")[2]) {
			case "1":
				strResult[3] = "0";
				strResult[4] = "无";
				break;
			case "2":
				strResult[3] = "1";
				strResult[4] = "轻度";
				break;
			case "3":
				strResult[3] = "2";
				strResult[4] = "中度";
				break;
			case "4":
				strResult[3] = "3";
				strResult[4] = "重度";
				break;
			case "5":
				strResult[3] = "4";
				strResult[4] = "极重";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 四十四、护士用住院病人观察Nosie
	private String[] GetNosieReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "社会能力,社会兴趣,个人整洁,激怒,迟缓,抑郁,精神病表现,总积极因素,总消极因素,总分".split(",");
			String[] geName = "Shnl,Shxq,Grzj,Jn,Ch,Yy,Jsbbx,Zjjys,Zxjys,Total".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i] + "_o") + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			strResult[3] = "0";
			strResult[4] = "";

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 四十五、密西根酒精调查表Mast
	private String[] GetMastReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "总分,诊断结果".split(",");
			String[] geName = "Total_o,Total_a".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i]) + "</td></tr>";
				}
				strResult[1] += "</table>";
			}
			switch (String.valueOf(map.get("total_a"))) {
			case "无":
				strResult[3] = "0";
				strResult[4] = "无";
				break;
			case "低":
				strResult[3] = "0";
				strResult[4] = "低";
				break;
			case "轻":
				strResult[3] = "1";
				strResult[4] = "无";
				break;
			case "中度":
				strResult[3] = "2";
				strResult[4] = "中度";
				break;
			case "较重":
				strResult[3] = "3";
				strResult[4] = "较重";
				break;
			case "严重":
				strResult[3] = "4";
				strResult[4] = "严重";
				break;
			}
			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 四十六、老年临床评定量表Scap
	private String[] GetScapReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "总分,总体印象分".split(",");
			String[] geName = "total,totalimpress".split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i] + "_o") + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			strResult[3] = "0";
			strResult[4] = "";

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 四十七、老年抑郁量表Gds
	private String[] GetGdsReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "总分,诊断结果".split(",");
			String[] geName = "Total_o,Total_a".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i]) + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			switch (String.valueOf(map.get("total_a"))) {
			case "正常":
				strResult[3] = "0";
				strResult[4] = "正常";
				break;
			case "轻度抑郁":
				strResult[3] = "1";
				strResult[4] = "轻度抑郁";
				break;
			case "中重度抑郁":
				strResult[3] = "2";
				strResult[4] = "中重度抑郁";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 四十八、痴呆简易筛查量表Bssd
	private String[] GetBssdReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			// 因子得分
			if (g_inblFactor) {
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">总分</td><td" + subValue(0, -1) + ">"
						+ map.get("total_o") + "</td></tr>";
				// strResult[1] += "<tr><td" + subTitle(0, -1) + ">教育状况</td><td" + subValue(0,
				// -1) + ">" + vEducation + "</td></tr>";
				strResult[1] += "<tr><td" + subTitle(0, -1) + ">诊断结果</td><td" + subValue(0, -1) + ">"
						+ map.get("total_a") + "</td></tr>";
				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			switch (String.valueOf(map.get("total_d")).split("\\.")[2]) {
			case "1":
				strResult[3] = "0";
				strResult[4] = "正常";
				break;
			case "2":
				strResult[3] = "1";
				strResult[4] = "认知功能轻度受损";
				break;
			case "3":
				strResult[3] = "2";
				strResult[4] = "认知功能明显受到损害";
				break;
			case "4":
				strResult[3] = "3";
				strResult[4] = "认知功能严重受损";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 四十九、缺血指数量表His
	private String[] GetHisReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "Hachinski指数,Rosen指数,诊断结果".split(",");
			String[] geName = "Hach_o,Rosen_o,Hach_a".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, oWidth * 3) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i]) + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			switch (String.valueOf(map.get("hach_d")).split("\\.")[2]) {
			case "1":
				strResult[3] = "1";
				strResult[4] = "属老年性痴呆    (Hachinski指数)";
				break;
			case "2":
				strResult[3] = "2";
				strResult[4] = "属混合性痴呆    (Hachinski指数)";
				break;
			case "3":
				strResult[3] = "3";
				strResult[4] = "属血管性痴呆    (Hachinski指数)";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 五十、长谷川痴呆量表Hds
	private String[] GetHdsReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">总分</td><td" + subValue(0, -1) + ">"
						+ map.get("total_o") + "</td></tr>";
				strResult[1] += "<tr><td" + subTitle(0, -1) + ">诊断结果</td><td" + subValue(0, -1) + ">"
						+ map.get("total_a") + "</td></tr>";

				strResult[1] += "</table>";
			}

			switch (String.valueOf(map.get("total_a"))) {
			case "正常":
				strResult[3] = "0";
				strResult[4] = "正常";
				break;
			case "痴呆":
			case "可能有痴呆":
				strResult[3] = "*";
				strResult[4] = String.valueOf(map.get("total_a"));
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 五十一、简易智力状态检查Mmse
	// ---table_uuid: 9DA86AE7-4BF3-4E2A-A80B-B4EC73F22E9B
	private String[] GetMmseReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {

			if (g_inblFactor) {
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">总分</td><td" + subValue(0, -1) + ">"
						+ map.get("total_o") + "</td></tr>";
				// strResult[1] += "<tr><td" + subTitle(0, -1) + ">教育状况</td><td" + subValue(0,
				// -1) + ">" + vEducation + "</td></tr>";
				strResult[1] += "<tr><td" + subTitle(0, -1) + ">诊断结果</td><td" + subValue(0, -1) + ">"
						+ map.get("total_a") + "</td></tr>";

				strResult[1] += "</table>";
			}
			strResult[2] = String.valueOf(map.get("total_d"));

			switch (String.valueOf(map.get("total_d")).split("\\.")[2]) {
			case "1":
				strResult[3] = "0";
				strResult[4] = "正常";
				break;
			case "2":
				strResult[3] = "1";
				strResult[4] = "认知功能轻度受损";
				break;
			case "3":
				strResult[3] = "2";
				strResult[4] = "认知功能中度受损";
				break;
			case "4":
				strResult[3] = "3";
				strResult[4] = "认知功能受损明显";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 五十二、五十三、五十四、五十五、儿童行为量表(男6-11岁)Cbclm1、(男12-16岁)Cbclm2、(女6-11岁)Cbclf1、(女12-16岁)Cbclf1
	private String[] GetCbclReport(Map<String, Object> map, int vSex, float vAge) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i, j;
			String[] gcName1 = "总粗分,活动能力,社交能力,学习能力".split(",");
			String[] geName1 = "Total,Hdnl,Sjnl,Xxnl".toLowerCase().split(",");

			String strCname2 = "";
			String strSname2 = "";

			String[] gcName2 = null;
			String[] gsName2 = null;

			String strCode = "";

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName1.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, -1) + ">" + gcName1[i] + "</td><td" + subValue(0, -1) + ">"
							+ map.get(geName1[i] + "_o") + "</td></tr>";
				}

				if (vSex == 1) // 男
				{
					if (vAge < 6) // 4-5
					{
						strCname2 = "社交退缩,躯体诉述,抑郁,幼稚不成熟,性问题,分裂样,攻击,违纪";
						strSname2 = "6-7,4-5,13-14,10-11,1-2,4-5,19-20,4-5";
					} else if (6 < vAge && vAge < 12) // 6-11
					{
						strCname2 = "分裂样,抑郁,交往不良,强迫性,体诉,社交退缩,多动,攻击性,违纪";
						strSname2 = "5-6,9-10,5-6,8-9,6-7,5-6,10-11,19-20,7-8";
					} else // 12-16
					{
						strCname2 = "体诉,分裂样,交往不良,不成熟,强迫性,敌意性,违纪,攻击性,多动";
						strSname2 = "10-11,7-8,14-15,5-6,5-6,10-11,8-9,18-19,9-10";
					}
				} else // 女
				{
					if (vAge < 6) // 4-5
					{
						strCname2 = "抑郁,躯体诉述,分裂样,社交退缩,性问题,肥胖,攻击,多动";
						strSname2 = "9-10,10-11,8-9,7-8,2-3,3-4,14-15,5-6";
					} else if (6 < vAge && vAge < 12) // 6-11
					{
						strCname2 = "抑郁,社交退缩,体诉,分裂强迫,多动,性问题,违纪,攻击性,残忍";
						strSname2 = "3-4,8-9,8-9,3-4,10-11,3-4,2-3,18-19,3-4";
					} else // 12-16
					{
						strCname2 = "焦虑强迫,体诉,分裂样,抑郁退缩,不成熟,违纪,攻击性,残忍";
						strSname2 = "17-18,7-8,3-4,12-13,11-12,11-12,17-18,4-5";
					}
				}

				gcName2 = strCname2.split(",");
				gsName2 = strSname2.split(",");

				for (i = 0; i < gcName2.length; i = i + 2) {
					strResult[1] += "<tr>";
					for (j = 0; j < 2; j++) {
						if (i + j > gcName2.length - 1) {
							break;
						}
						strResult[1] += "<td" + subTitle(0, tWidth) + ">" + gcName2[i + j] + "</td><td"
								+ subValue(0, tWidth) + ">" + map.get("factor" + (i + j + 1) + "_o") + "</td>" + "<td"
								+ subValue(0, tWidth) + ">(参考分界值" + gsName2[i + j] + ")" + "</td>";

						strCode += String.valueOf(map.get("factor" + String.valueOf(i + j + 1) + "_d")) + "|";
					}
					strResult[1] += "</tr>";

				}
				strResult[1] += "</table>";
			}

			if (strCode.length() > 0) {
				strCode = strCode.substring(0, strCode.length() - 1);
			}

			strResult[2] = strCode;

			for (i = 0; i < strCode.split("\\|").length; i++) {
				if (strCode.split("\\|")[i].split("\\.")[2].equals("3")) {
					strResult[3] = "*";
					strResult[4] += gcName2[i] + "异常，";
				}
			}

			if (strResult[4].length() > 0) {
				strResult[4] = strResult[4].substring(0, strResult[4].length() - 1);
			} else {
				strResult[3] = "0";
				strResult[4] = "正常";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 五十六、Conners父母量表Conn
	private String[] GetConnReport(Map<String, Object> map, int vSex, float vAge) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i, j;
			String strSname = "";

			String[] gcName = "品德问题,学习问题,心身障碍,冲动-多动,焦虑,多动指数".split(",");
			String[] geName = "Pxwt,Xxwt,Xsza,Cddd,Jl,Ddzs".toLowerCase().split(",");

			if (vSex == 1) // 男
			{
				if (vAge < 6) // 3-5
				{
					strSname = "0.53±0.39,0.50±0.33,0.07±0.15,1.01±0.65,0.61±0.61,0.72±0.40";
				} else if (6 <= vAge && vAge < 9) // 6-8
				{
					strSname = "0.50±0.40,0.64±0.45,0.13±0.23,0.92±0.60,0.51±0.51,0.69±0.46";
				} else if (9 <= vAge && vAge < 12) // 9-11
				{
					strSname = "0.53±0.38,0.54±0.52,0.18±0.26,0.93±0.60,0.42±0.47,0.66±0.44";
				} else if (12 <= vAge && vAge < 15) // 12-14
				{
					strSname = "0.49±0.41,0.66±0.57,0.22±0.44,0.82±0.54,0.58±0.59,0.62±0.45";
				} else // 15-17
				{
					strSname = "0.47±0.44,0.62±0.55,0.13±0.26,0.70±0.51,0.59±0.58,0.51±0.41";
				}
			} else // 女
			{
				if (vAge < 6) // 3-5
				{
					strSname = "0.49±0.35,0.62±0.57,0.10±0.17,1.15±0.77,0.51±0.59,0.78±0.56";
				} else if (6 <= vAge && vAge < 9) // 6-8
				{
					strSname = "0.41±0.28,0.45±0.38,0.19±0.27,0.95±0.59,0.57±0.66,0.59±0.35";
				} else if (9 <= vAge && vAge < 12) // 9-11
				{
					strSname = "0.40±0.36,0.43±0.38,0.17±0.28,0.80±0.59,0.49±0.57,0.52±0.34";
				} else if (12 <= vAge && vAge < 15) // 12-14
				{
					strSname = "0.39±0.40,0.44±0.45,0.23±0.28,0.72±0.55,0.54±0.53,0.49±0.34";
				} else // 15-17
				{
					strSname = "0.37±0.33,0.35±0.38,0.19±0.25,0.60±0.55,0.51±0.53,0.42±0.34";
				}
			}

			String[] gsName = strSname.split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">指标</td><td" + subTitle(0, oWidth / 2 * 3)
						+ ">平均分</td><td" + subTitle(0, tWidth + oWidth / 2) + ">均分与标准差</td>" + "<td"
						+ subTitle(0, tWidth) + ">指标</td><td" + subTitle(0, oWidth / 2 * 3) + ">平均分</td><td"
						+ subTitle(0, -1) + ">均分与标准差</td></tr>";
				for (i = 0; i < gcName.length; i = i + 2) {
					strResult[1] += "<tr>";
					for (j = 0; j < 2; j++) {
						strResult[1] += "<td" + subTitle(0, -1) + ">" + gcName[i + j] + "</td><td" + subValue(0, -1)
								+ ">" + map.get(geName[i + j] + "_ave") + "</td>" + "<td" + subValue(0, -1) + ">"
								+ gsName[i + j] + "</td>";
					}
					strResult[1] += "</tr>";
				}
				strResult[1] += "</table>";
			}

			String strCode = "";
			for (i = 0; i < gcName.length; i++) {
				if (map.get(geName[i] + "_d").toString().length() > 0) {
					strCode += map.get(geName[i] + "_d") + "|";
				}
			}

			if (strCode.length() > 0) {
				strCode = strCode.substring(0, strCode.length() - 1);
			}

			strResult[2] = strCode;

			for (i = 0; i < gcName.length; i++) {
				if (!String.valueOf(map.get(geName[i] + "_d")).equals("")) {
					if (String.valueOf(map.get(geName[i] + "_d")).split("\\.")[2].equals("1")) {
						strResult[3] = "*";
						strResult[4] += gcName[i].toString() + "异常" + "，";
					}
				}

			}

			if (strResult[4].length() > 0) {
				strResult[4] = strResult[4].substring(0, strResult[4].length() - 1);
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 五十七、个人评价问卷Pei
	private String[] GetPeiReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "总分,诊断结果".split(",");
			String[] geName = "Total_o,Total_a".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i]) + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			if (String.valueOf(map.get("total_a")).equals("无自信")) {
				strResult[3] = "*";
				strResult[4] = "无自信";
			} else {
				strResult[3] = "0";
				strResult[4] = "正常";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 五十八、A型行为A
	private String[] GetAReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName1 = ",时间匆忙感特征,争强好胜，怀有戒心或敌意特征,谎分,诊断结果".split(",");
			String[] gdName1 = ",TH,CH,L,诊断结果".split(",");
			String[] geName1 = "Lie_a,Sjcm_o,Zqhs_o,Lie_o,Total_a".toLowerCase().split(",");

			String[] geName2 = "Sjcm_d,Zqhs_d,Lie_d,Total_d".toLowerCase().split(",");

			String[] gvName1 = {};
			switch (g_CorE) {
			case 1:
				gvName1 = gcName1;
				break;
			case 2:
				gvName1 = gdName1;
				break;
			}

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName1.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth * 3) + ">" + gvName1[i] + "</td><td"
							+ subValue(0, -1) + ">" + map.get(geName1[i]);
					if (i == gcName1.length - 1) {
						if (Integer.valueOf(String.valueOf(map.get("total_o"))) >= 29) // A型, A-型
						{
							strResult[1] += red_Asterisk;
						}
					}
					strResult[1] += "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			String strCode = "";
			for (i = 0; i < geName2.length; i++) {
				if (map.get(geName2[i]).toString().length() > 0) {
					strCode += map.get(geName2[i]).toString() + "|";
				}
			}
			if (strCode.length() > 0) {
				strCode = strCode.substring(0, strCode.length() - 1);
			}

			strResult[2] = strCode;

			if (String.valueOf(map.get("lie_d")).equals("测验时有掩饰或不认真的现象")) {
				strResult[3] = "*";
				strResult[4] = "测验时有掩饰或不认真的现象";
			} else {
				strResult[3] = "0";
				strResult[4] = "正常";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 五十九、疲劳量表Fs14
	private String[] GetFs14Report(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "躯体疲劳分值,脑力疲劳分值,总分".split(",");
			String[] geName = "Qtpl,Nlpl,Total".toLowerCase().split(",");
			String[] gsName = "0-8,0-6,0-14".split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth * 2) + ">" + gcName[i] + "</td><td"
							+ subValue(0, tWidth) + ">" + map.get(geName[i] + "_o") + "</td>" + "<td" + subValue(0, -1)
							+ ">分值范围" + gsName[i] + "</td></tr>";
				}
				strResult[1] += "<tr><td colspan='3'" + subTitle(0, -1) + ">分值越高，疲劳程度越严重</td><tr>";

				strResult[1] += "</table>";
			}

			strResult[3] = "0";
			strResult[4] = "";

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 六十、匹茨堡睡眠质量指数Psqi
	// ---table_uuid: 72141F13-F699-417F-B5F1-ECD0928DA88C
	private String[] GetPsqiReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "主观睡眠质量总分,睡眠潜伏期总分,睡眠持续性总分,习惯性睡眠效率总分,睡眠紊乱总分,使用睡眠药物总分,白天功能紊乱总分,睡眠质量指数总评".split(",");
			String[] geName = "Zgsmzl,Smqfq,Smcxx,Xgxsm,Smwl,Sysmyw,Btgnwl,Smzlzs".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					if (i == 7) {
						String strYxsm = "没有";
						if (map.get("yxsm_a").toString().length() > 0) {
							strYxsm = String.valueOf(map.get("yxsm_a"));
						}
						strResult[1] += "<tr><td" + subTitle(0, -1) + ">影响睡眠的其他原因</td><td colspan='2'" + subValue(0, -1)
								+ ">" + strYxsm + "</td></tr>";
					}
					strResult[1] += "<tr><td" + subTitle(0, tWidth * 2) + ">" + gcName[i] + "</td><td"
							+ subValue(0, tWidth) + ">" + map.get(geName[i] + "_s") + "</td>" + "<td" + subValue(0, -1)
							+ ">" + map.get(geName[i] + "_a") + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			switch (String.valueOf(map.get("smzlzs_a"))) {
			case "睡眠质量没有困难":
				strResult[3] = "0";
				strResult[4] = "睡眠质量正常";
				break;
			case "睡眠质量少数方面有困难":
				strResult[3] = "1";
				strResult[4] = "睡眠质量少数方面有困难";
				break;
			case "睡眠质量较多方面有困难":
				strResult[3] = "2";
				strResult[4] = "睡眠质量较多方面有困难";
				break;
			case "睡眠质量几乎所有方面都非常困难":
				strResult[3] = "3";
				strResult[4] = "睡眠质量几乎所有方面都非常困难";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 六十一、UCLA孤独量表Ucla
	private String[] GetUclaReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "总分原始分,总分标准分".split(",");
			String[] geName = "Total_o,Total_s".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i]) + "</td></tr>";
				}

				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			switch (String.valueOf(map.get("total_d")).split("\\.")[2]) {
			case "1":
				strResult[3] = "0";
				strResult[4] = "正常";
				break;
			case "2":
				strResult[3] = "1";
				strResult[4] = "轻度";
				break;
			case "3":
				strResult[3] = "2";
				strResult[4] = "中度";
				break;
			case "4":
				strResult[3] = "3";
				strResult[4] = "重度";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 六十三、阿森其失眠量表Asssm
	private String[] GetAsssmReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "总分,诊断结果".split(",");
			String[] geName = "Total_o,Total_a".toLowerCase().split(",");
			String[] gsName = "总分范围(0-24), ".split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName[i] + "</td><td" + subValue(0, tWidth)
							+ ">" + map.get(geName[i]) + "</td>" + "<td" + subValue(0, -1) + ">" + gsName[i]
							+ "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			switch (String.valueOf(map.get("total_a"))) {
			case "无睡眠障碍":
				strResult[3] = "0";
				strResult[4] = "无睡眠障碍";
				break;
			case "可疑失眠":
				strResult[3] = "1";
				strResult[4] = "可疑失眠";
				break;
			case "失眠":
				strResult[3] = "2";
				strResult[4] = "失眠";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 六十四、防御方式问卷Dsq
	private String[] GetDsqReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "不成熟防御机制,成熟机制,中间型防御机制,掩饰机制".split(",");
			String[] geName = "Bcsfy,Csjz,Zjxfy,Ysjz".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth * 2) + "></td><td" + subTitle(0, tWidth) + ">原始分</td><td"
						+ subTitle(0, -1) + ">平均分</td></tr>";
				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, -1) + ">" + gcName[i] + "</td><td" + subValue(0, -1) + ">"
							+ map.get(geName[i] + "_o") + "</td>" + "<td" + subValue(0, -1) + ">"
							+ map.get(geName[i] + "_ave") + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			String strCode = "";
			for (i = 0; i < gcName.length; i++) {
				strCode += map.get(geName[i] + "_d") + "|";
			}

			if (strCode.length() > 0) {
				strCode = strCode.substring(0, strCode.length() - 1);
			}

			strResult[2] = strCode;

			strResult[3] = "0";
			strResult[4] = "";

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 六十五、应付方式问卷Yffs
	private String[] GetYffsReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "解决问题,合理化,自责,求助,幻想,退避".split(",");
			String[] geName = "Jjwt,Hlh,Zz,Qz,Hx,Tb".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">因子</td><td" + subTitle(0, tWidth) + ">倾向性</td><td"
						+ subTitle(0, -1) + ">有效性</td></tr>";
				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, -1) + ">" + gcName[i] + "</td><td" + subValue(0, -1) + ">"
							+ map.get(geName[i] + "_t") + "</td>" + "<td" + subValue(0, -1) + ">"
							+ map.get(geName[i] + "_v") + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			strResult[3] = "0";
			strResult[4] = "";

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 六十六、生活事件量表Les
	private String[] GetLesReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i, j;
			String[] gcName1 = "负性事件,正性事件,中性事件,总分".split(",");
			String[] geName1 = "Fxsj,Exsj,Zxsj,Total".toLowerCase().split(",");

			String[] gcName2 = "学习,婚姻,健康,家庭,工作与经济,人际关系,环境问题,法律与政治".split(",");
			String[] geName2 = "Xx,Hy,Jk,Jt,Gzyjj,Rjgx,Hjwt,Flyzz".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + "></td><td" + subTitle(0, tWidth) + ">频度</td><td"
						+ subTitle(0, tWidth) + ">强度</td>" + "<td" + subTitle(0, tWidth) + "></td><td"
						+ subTitle(0, tWidth) + ">频度</td><td" + subTitle(0, tWidth) + ">强度</td></tr>";
				for (i = 0; i < gcName1.length; i = i + 2) {
					strResult[1] += "<tr>";
					for (j = 0; j < 2; j++) {
						strResult[1] += "<td" + subTitle(0, -1) + ">" + gcName1[i + j] + "</td><td" + subValue(0, -1)
								+ ">" + map.get(geName1[i + j] + "_f") + "</td>" + "<td" + subValue(0, -1) + ">"
								+ map.get(geName1[i + j] + "_i") + "</td>";
					}
					strResult[1] += "</tr>";
				}

				strResult[1] += "<tr><td" + subTitle(0, -1) + ">因子</td><td" + subTitle(0, -1) + ">频度</td><td"
						+ subTitle(0, -1) + ">强度</td>" + "<td" + subTitle(0, -1) + ">因子</td><td" + subTitle(0, -1)
						+ ">频度</td><td" + subTitle(0, -1) + ">强度</td></tr>";
				for (i = 0; i < gcName2.length; i = i + 2) {
					strResult[1] += "<tr>";
					for (j = 0; j < 2; j++) {
						strResult[1] += "<td" + subTitle(0, -1) + ">" + gcName2[i + j] + "</td><td" + subValue(0, -1)
								+ ">" + map.get(geName2[i + j] + "_f") + "</td>" + "<td" + subValue(0, -1) + ">"
								+ map.get(geName2[i + j] + "_i") + "</td>";
					}
					strResult[1] += "</tr>";
				}
				strResult[1] += "</table>";
			}

			strResult[3] = "0";
			strResult[4] = "";

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 六十七、社会支持评定量表Issi $$“医生意见”在内部，比较特殊后期处理
	private String[] GetIssiReport(Map<String, Object> map, String vTable_uuid, String vAnswerString) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i, j, k;
			String gcName1[] = "总分,客观支持分,主观支持分,对支持的利用度".split(",");
			String geName1[] = "Total,Kgzc,Zgzc,Zclyd".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";
				for (i = 0; i < gcName1.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth * 2) + ">" + gcName1[i] + "</td><td"
							+ subValue(0, -1) + ">" + map.get(geName1[i] + "_o") + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			// String[] strAnswer = vAnswerString.split("@@");
			String[] sAnswer;

			// ************************************************************************************
			int intI;
			// 转换回原来格式
			String[] strTemp1 = vAnswerString.split("\\|");
			String strAnswer10 = strTemp1[9].split("&")[0];
			String strAnswer11 = strTemp1[10].split("&")[0];
			String strAnswer10_Other1 = "";
			if (strTemp1[9].split("&").length > 1) {
				if (!strTemp1[9].split("&")[1].equals("@")) {
					strAnswer10_Other1 = strTemp1[9].split("&")[1].split("@")[0];
				}
			}

			String strAnswer10_Other2 = "";
			if (strTemp1[9].split("@").length > 1) {
				strAnswer10_Other2 = strTemp1[9].split("@")[1];
			}

			if (strAnswer10_Other1.equals("")) {
				strAnswer10_Other1 = "0|0|0|0|0|0|0|0|0|" + strAnswer10_Other2;
			} else {
				String[] strAnswer10_Other1_Temp = { "0", "0", "0", "0", "0", "0", "0", "0", "0" };
				for (intI = 0; intI < strAnswer10_Other1.split("\\$").length; intI++) {
					strAnswer10_Other1_Temp[Integer.valueOf(String.valueOf(strAnswer10_Other1.split("\\$")[intI]))
							- 1] = "1";
				}
				strAnswer10_Other1 = "";
				for (intI = 0; intI < strAnswer10_Other1_Temp.length; intI++) {
					strAnswer10_Other1 += strAnswer10_Other1_Temp[intI] + "|";
				}
				strAnswer10_Other1 += strAnswer10_Other2;
			}

			String strAnswer11_Other1 = "";
			if (strTemp1[10].split("&").length > 1) {
				if (!strTemp1[10].split("&")[1].equals("@")) {
					strAnswer11_Other1 = strTemp1[10].split("&")[1].split("@")[0];
				}
			}

			String strAnswer11_Other2 = "";
			if (strTemp1[10].split("$@").length > 1) {
				strAnswer11_Other2 = strTemp1[10].split("$@")[1];
			}

			if (strAnswer11_Other1.equals("")) {
				strAnswer11_Other1 = "0|0|0|0|0|0|0|0|0|" + strAnswer11_Other2;
			} else {
				String[] strAnswer11_Other1_Temp = { "0", "0", "0", "0", "0", "0", "0", "0", "0" };
				for (intI = 0; intI < strAnswer11_Other1.split("\\$").length; intI++) {
					strAnswer11_Other1_Temp[Integer.valueOf(strAnswer11_Other1.split("\\$")[intI]) - 1] = "1";
				}
				strAnswer11_Other1 = "";
				for (intI = 0; intI < strAnswer11_Other1_Temp.length; intI++) {
					strAnswer11_Other1 += strAnswer11_Other1_Temp[intI] + "|";
				}
				strAnswer11_Other1 += strAnswer11_Other2;
			}

			String strTemp = "";
			for (intI = 0; intI < strTemp1.length; intI++) {
				switch (intI) {
				case 9:
					strTemp += strAnswer10 + "|";
					break;
				case 10:
					strTemp += strAnswer11 + "|";
					break;
				default:
					strTemp += strTemp1[intI] + "|";
					break;
				}
			}

			strTemp = strTemp.substring(0, strTemp.length() - 1) + "@@" + strAnswer10_Other1 + "@@"
					+ strAnswer11_Other1;

			// 临时赋值，JAVA默认切割时为空就不增加数组长度
			String[] strAnswer_c_Temp = strTemp.split("@@");
			String[] strAnswer = { "", "", "" };
			for (intI = 0; intI < strAnswer_c_Temp.length; intI++) {
				strAnswer[intI] = strAnswer_c_Temp[intI].trim();
			}
			// ************************************************************************************

			if (strAnswer.length == 3) // 正确，共三份
			{
				String[] gcName2 = "其他物质帮助来源,其他精神支持来源".split(",");

				strResult[2] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";
				for (i = 0; i < gcName2.length; i++) {
					String[] strOther = strAnswer[i + 1].split("\\|");
					if (strOther.length == 10) {
						strResult[2] += "<tr><td" + subTitle(0, tWidth * 2) + ">" + gcName2[i] + "</td><td"
								+ subValue(0, -1) + ">" + strOther[strOther.length - 1] + "</td></tr>";
					} else {
						strResult[2] += "<tr><td" + subTitle(0, tWidth * 2) + ">" + gcName2[i] + "</td><td"
								+ subValue(0, -1) + ">" + "" + "</td></tr>";
					}
				}
				strResult[2] += "</table>";
				strResult[2] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";
				for (i = 1; i < gcName1.length; i++) // 客观支持，主观支持，对支持的利用度
				{
					if (map.get(geName1[i] + "_d").toString().length() > 0) {
						strResult[2] += "<tr><td" + subValue(0, -1) + ">"
								+ getTableDiagnosis(map.get(geName1[i] + "_d").toString()).getDiagnosis_content()
								+ "</td></tr>";
					}

					sAnswer = strAnswer[0].split("\\|"); // , m_nChar)
					// 对应的“选择项”或“其他”输入
					switch (i) {
					case 1: // 客观支持(第10题，第11题)
						String[] gcName3 = "能够得到的物质帮助来源有,能够得到的精神支持来源有".split(",");
						String[] gsName3 = "配偶,其他家人,朋友,亲戚,同事,工作单位,党团工会等官方或半官方组织,宗教、社会团体等非官方组织".split(",");

						for (j = 0; j < gcName3.length; j++) {
							strResult[2] += "<tr><td" + subTitle(0, -1) + ">" + gcName3[j] + "</td></tr>";

							if (Integer.valueOf(sAnswer[9 + j]) == 2) // 有支持
							{
								String[] sSel = strAnswer[j + 1].split("\\|");
								for (k = 0; k < gsName3.length; k++) {
									if (Integer.valueOf(sSel[k]) == 1) // 有
									{
										strResult[2] += "<tr><td" + subValue(0, -1) + ">" + tSpace + gsName3[k]
												+ "</td></tr>";
									}
								}
							} else {
								strResult[2] += "<tr><td" + subValue(0, -1) + ">" + tSpace + "无</td></tr>";
							}
						}
						break;
					case 2: // 主观支持(第3题--第9题，3、4显示选择项，5--9显示题目及选择项，选择了“3”或“4”)
						String[] gcName4 = ",,夫妻(恋人),父母,儿女,兄弟姐妹,家庭其他成员(如嫂子)".split(",");
						String[] gsName4 = "有些邻居很关心您,大多数邻居都很关心您,有些同事很关心您,大多数同事都很关心您,一般,全力支持".split(",");

						strResult[2] += "<tr><td" + subTitle(0, -1) + ">" + "主观体验到支持的他人</td></tr>";

						for (j = 0; j < gcName4.length; j++) {
							int intIndex = Integer.valueOf(sAnswer[2 + j]);
							switch (intIndex) {
							case 3:
							case 4:
								if (gcName4[j].length() > 0) {
									strResult[2] += "<tr><td" + subValue(0, -1) + ">" + tSpace + "从" + gcName4[j]
											+ "得到的支持和照顾：" + gsName4[4 + intIndex - 3] + "</td></tr>";
								} else {
									strResult[2] += "<tr><td" + subValue(0, -1) + ">" + tSpace
											+ gsName4[j * 2 + intIndex - 3] + "</td></tr>";
								}
								break;
							default:
								break;
							}
						}
						break;
					case 3: // 对支持的利用度(应对烦恼的方式：（显示第12、13题所选项）；对团体活动的态度：（显示第14题所选项）)
						String[][] strQuesSelectA = {
								{ "从不向任何人诉述", "只向关系极为密切的1—2个人诉述", "如果朋友主动询问您会说出来", "主动诉述自己的烦恼，以获得支持和理解" },
								{ "只靠自己，不接受别人帮助", "很少请求别人帮助", "有时请求别人帮助", "有困难时经常向家人、亲友、组织求援" },
								{ "从不参加", "偶尔参加", "经常参加", "主动参加并积极活动" } };

						String strName5 = "从不向任何人诉述,只向关系极为密切的1—2个人诉述,如果朋友主动询问您会说出来,主动诉述自己的烦恼，以获得支持和理解,"
								+ "只靠自己，不接受别人帮助,很少请求别人帮助,有时请求别人帮助,有困难时经常向家人、亲友、组织求援,从不参加,偶尔参加,经常参加,主动参加并积极活动";
						String[] gcName5 = strName5.split(",");

						strResult[2] += "<tr><td" + subTitle(0, -1) + ">应对烦恼的方式：" + "</td></tr>";
						strResult[2] += "<tr><td" + subValue(0, -1) + ">" + tSpace
								+ gcName5[Integer.valueOf(sAnswer[11]) - 1] + "</td></tr>"; // 第12题
						strResult[2] += "<tr><td" + subValue(0, -1) + ">" + tSpace
								+ gcName5[Integer.valueOf(sAnswer[12]) + 4 - 1] + "</td></tr>"; // 第13题

						strResult[2] += "<tr><td" + subTitle(0, -1) + ">对团体活动的态度：" + "</td></tr>";
						strResult[2] += "<tr><td" + subValue(0, -1) + ">" + tSpace
								+ gcName5[Integer.valueOf(sAnswer[12]) + 8 - 1] + "</td></tr>"; // 第14题
						break;
					}
				}
				strResult[2] += "</table>";
			}

			strResult[3] = "0";
			strResult[4] = "";

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 六十八、简易应对方式Jyyd
	private String[] GetJyydReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "积极应对,消极应对".split(",");
			String[] geName = "Jjyd,Xjyd".toLowerCase().split(",");
			String[] gsName = "0-36,0-24".split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName[i] + "</td><td" + subValue(0, tWidth)
							+ ">" + map.get(geName[i] + "_o") + "</td>" + "<td" + subValue(0, -1) + ">分值范围" + gsName[i]
							+ "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			strResult[3] = "0";
			strResult[4] = "";

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 六十九、家庭环境量表Fes
	private String[] GetFesReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "亲密度,情感表达,矛盾性,独立性,成功性,知识性,娱乐性,道德宗教观,组织性,控制性".split(",");
			String[] geName = "Qmd,Qgbd,Mdx,Dlx,Cgx,Zsx,Ylx,Ddzjg,Zzx,Kzx".toLowerCase().split(",");
			String[] gsName = "(7.7±1.9),(5.8±1.7),(2.2±1.9),(5.8±1.4),(6.8±1.7),(5.6±2.1),(4.9±2.0),(5.3±1.4),(6.7±1.8),(3.6±1.8)"
					.split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + "></td><td" + subTitle(0, tWidth) + ">因子得分</td><td"
						+ subTitle(0, -1) + ">均分与标准差</td></tr>";
				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, -1) + ">" + gcName[i] + "</td><td" + subValue(0, -1) + ">"
							+ map.get(geName[i] + "_o") + "</td><td" + subValue(0, -1) + ">" + gsName[i] + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			String strCode = "";
			for (i = 0; i < gcName.length; i++) {
				strCode += map.get(geName[i] + "_d") + "|";
			}

			if (strCode.length() > 0) {
				strCode = strCode.substring(0, strCode.length() - 1);
			}

			strResult[2] = strCode;

			for (i = 0; i < gcName.length; i++) {
				if (String.valueOf(map.get(geName[i] + "_d")).split("\\.")[2].equals("1")) {
					strResult[3] = "*";
					strResult[4] += gcName[i].toString() + "低" + "，";
				}
			}

			if (strResult[4].length() > 0) {
				strResult[4] = strResult[4].substring(0, strResult[4].length() - 1);
			} else {
				strResult[3] = "0";
				strResult[4] = "";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 七十、OLSON婚姻质量问卷Olson
	private String[] GetOlsonReport(Map<String, Object> map, int vSex) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "过分理想化,婚姻满意度,性格相容性,夫妻交流,解决冲突的方式,经济安排,业余活动,性生活,子女和婚姻,与亲友的关系,角色平等性,信仰一致性".split(",");
			String[] geName = "Gflxh,Hymyd,Xgxrx,Fqjl,Jjct,Jjap,Yyhd,Xsh,Znhhy,Yqygx,Jspdx,Xyyzx".toLowerCase()
					.split(",");

			String strAvg = "";
			if (vSex == 1) // 男
			{
				strAvg = ",37.31±6.45,34.58±5.96,34.90±6.05,34.05±5.84,37.16±6.33,33.99±3.90,37.09±6.62,38.35±5.58,37.52±5.63,28.86±5.45,39.04±6.58";
			} else // 女
			{
				strAvg = ",37.04±7.03,34.43±6.35,34.10±6.94,33.85±6.43,37.65±6.78,34.81±4.38,37.60±6.90,38.25±5.72,38.55±5.90,28.06±5.80,40.04±6.26";
			}

			String[] gsName = strAvg.split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth * 2) + "></td><td" + subTitle(0, tWidth) + ">得分</td><td"
						+ subTitle(0, -1) + ">均分与标准差</td></tr>";
				strResult[1] += "<tr><td" + subTitle(0, -1) + ">总分</td><td colspan='2'" + subValue(0, -1) + ">"
						+ map.get("total_o") + "</td></tr>";
				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, -1) + ">" + gcName[i] + "</td><td" + subValue(0, -1) + ">"
							+ map.get(geName[i] + "_o") + "</td><td" + subValue(0, -1) + ">" + gsName[i] + "</td></tr>";
				}

				strResult[1] += "</table>";
			}

			String strCode = "";
			for (i = 0; i < gcName.length; i++) {
				strCode += map.get(geName[i] + "_d") + "|";
			}
			if (strCode.length() > 0) {
				strCode = strCode.substring(0, strCode.length() - 1);
			}

			strResult[2] = strCode;

			// 预警，详细说明每个因子的原因
			for (i = 0; i < gcName.length; i++) {
				if (String.valueOf(map.get(geName[i] + "_d")).split("\\.")[2].equals("1")) {
					strResult[3] = "*";
					switch (i) {
					case 0:
						strResult[4] += gcName[i].toString() + "对自己的婚姻评价低" + "，";
						break;
					case 1:
					case 2:
					case 3:
					case 4:
					case 5:
					case 6:
					case 7:
					case 8:
						strResult[4] += gcName[i].toString() + "非常不满意" + "，";
						break;
					case 9:
						strResult[4] += gcName[i].toString() + "非常不和谐" + "，";
						break;
					case 10:
						strResult[4] += gcName[i].toString() + "排斥" + "，";
						break;
					case 11:
						strResult[4] += gcName[i].toString() + "不一致" + "，";
						break;

					}

				}
			}

			if (strResult[4].length() > 0) {
				strResult[4] = strResult[4].substring(0, strResult[4].length() - 1);
			} else {
				strResult[3] = "0";
				strResult[4] = "";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 七十一、生活满意度量表Lsr
	private String[] GetLsrReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "总分,诊断结果".split(",");
			String[] geName = "Total_o,Total_a".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i]) + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			switch (String.valueOf(map.get("total_a"))) {
			case "满意":
				strResult[3] = "0";
				strResult[4] = "满意";
				break;
			case "一般":
				strResult[3] = "0";
				strResult[4] = "一般";
				break;
			case "不满意":
				strResult[3] = "*";
				strResult[4] = "不满意";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 七十二、生活满意度指数A Lsia
	private String[] GetLsiaReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			String gcName = "总分";
			String geName = "Total_o".toLowerCase();

			if (g_inblFactor) {
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";
				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName + "</td><td" + subValue(0, -1) + ">"
						+ map.get(geName) + "</td></tr>";
				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			switch (String.valueOf(map.get("total_d")).split("\\.")[2]) {
			case "1":
				strResult[3] = "0";
				strResult[4] = "满意";
				break;
			case "2":
				strResult[3] = "0";
				strResult[4] = "一般";
				break;
			case "3":
				strResult[3] = "*";
				strResult[4] = "不满意";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 七十三、生活满意度指数B Lsib
	private String[] GetLsibReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			String gcName = "总分";
			String geName = "Total_o".toLowerCase();
			if (g_inblFactor) {
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";
				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName + "</td><td" + subValue(0, -1) + ">"
						+ map.get(geName) + "</td></tr>";
				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			switch (String.valueOf(map.get("total_d")).split("\\.")[2]) {
			case "1":
				strResult[3] = "0";
				strResult[4] = "满意";
				break;
			case "2":
				strResult[3] = "0";
				strResult[4] = "一般";
				break;
			case "3":
				strResult[3] = "*";
				strResult[4] = "不满意";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 七十四、情感量表Motion
	private String[] GetMotionReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "正性情感,负性情感,情感平衡".split(",");
			String[] gdName = "PA,NA,AB".split(",");
			String[] geName = "Zxqg,Fxqg,Qgph".toLowerCase().split(",");

			String[] gvName = {};
			switch (g_CorE) {
			case 1:
				gvName = gcName;
				break;
			case 2:
				gvName = gdName;
				break;
			}

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gvName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i] + "_o") + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("qgph_d"));

			if (String.valueOf(map.get("qgph_d")).split("\\.")[2].equals("3")) {
				strResult[3] = "*";
				strResult[4] = "负性情感";
			} else {
				strResult[3] = "0";
				strResult[4] = "正常";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 七十五、总体幸福感量表 Gwb
	private String[] GetGwbReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			String gcName = "总分";
			String geName = "Total_o".toLowerCase();
			if (g_inblFactor) {
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName + "</td><td" + subValue(0, -1) + ">"
						+ map.get(geName) + "</td></tr>";

				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			if (String.valueOf(map.get("total_d")).split("\\.")[2].equals("3")) {
				strResult[3] = "*";
				strResult[4] = "缺乏幸福感";
			} else {
				strResult[3] = "0";
				strResult[4] = "正常";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 七十六、健康状况问卷 Sf36
	private String[] GetSf36Report(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "生理机能,生理职能,躯体疼痛,一般健康状况,精力,社会功能,情感职能,精神健康".split(",");
			String[] gdName = "PF,RP,BP,GH,VT,SF,RE,MH,HT".split(",");
			String[] geName = "Sljn,Slzn,Qttt,Ybjkzk,Jl,Shgn,Qgzn,Jsjk".toLowerCase().split(",");

			String strName = "";
			String[] gvName = {};
			switch (g_CorE) {
			case 1:
				gvName = gcName;
				strName = "健康变化情况";
				break;
			case 2:
				gvName = gdName;
				strName = "HT";
				break;
			}

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth * 2) + "></td><td" + subTitle(0, tWidth) + ">原始分</td><td"
						+ subTitle(0, -1) + ">标准分</td></tr>";
				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, -1) + ">" + gvName[i] + "</td><td" + subValue(0, -1) + ">"
							+ map.get(geName[i] + "_o") + "</td>" + "<td" + subValue(0, -1) + ">"
							+ map.get(geName[i] + "_s") + "</td></tr>";
				}
				strResult[1] += "<tr><td" + subTitle(0, -1) + ">" + strName + "</td><td colspan='2'" + subValue(0, -1)
						+ ">" + map.get("jkbh_a") + "</td></tr>";

				strResult[1] += "</table>";
			}

			switch (String.valueOf(map.get("jkbh_a"))) {
			case "比一年前差一些":
			case "比一年前差多了":
				strResult[3] = "*";
				strResult[4] = "健康变化情况" + String.valueOf(map.get("jkbh_a"));
				break;
			default:
				strResult[3] = "0";
				strResult[4] = "正常";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 七十七、勃起功能障碍指数问卷Ed
	private String[] GetEdReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "勃起功能障碍,总分".split(",");
			String[] geName = "Total_a,Total_o".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth * 2) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i]) + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			switch (String.valueOf(map.get("total_a"))) {
			case "未患ED":
			case "未患ed":
				strResult[3] = "0";
				strResult[4] = "正常";
				break;
			case "轻度ED，医生需要引起关注":
			case "轻度ed，医生需要引起关注":
				strResult[3] = "1";
				strResult[4] = "轻度ED，医生需要引起关注";
				break;
			case "中度ED，医生需要引起关注":
			case "中度ed，医生需要引起关注":
				strResult[3] = "2";
				strResult[4] = "中度ED，医生需要引起关注";
				break;
			case "严重ED，医生需要引起关注":
			case "严重ed，医生需要引起关注":
				strResult[3] = "3";
				strResult[4] = "严重ED，医生需要引起关注";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 七十八、婚姻满意度指数Spdall
	private String[] GetSpdallReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "情况,总分".split(",");
			String[] geName = "Total_a,Total_o".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i]) + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			switch (String.valueOf(map.get("total_a"))) {
			case "较差":
			case "差":
			case "严重":
			case "非常严重":
				strResult[3] = "*";
				strResult[4] = "异常";
				break;
			default:
				strResult[3] = "0";
				strResult[4] = String.valueOf(map.get("total_a"));
				break;
			/*
			 * case "较差": strResult[3] = "1"; strResult[4] =
			 * String.valueOf(map.get("total_a")); break; case "差": strResult[3] = "2";
			 * strResult[4] = String.valueOf(map.get("total_a")); break; case "严重":
			 * strResult[3] = "3"; strResult[4] = String.valueOf(map.get("total_a")); break;
			 * case "非常严重": strResult[3] = "4"; strResult[4] =
			 * String.valueOf(map.get("total_a")); break; default: strResult[3] = "0";
			 * strResult[4] = String.valueOf(map.get("total_a")); break;
			 */
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 七十九、男性性满意度指数Spdm
	private String[] GetSpdmReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "频率(INF),无交流(NCO),男性不满足(DISM),男性回避(AVM),男性无性感(NSM),阳痿(IMPM),早泄(PE),总分(ZF)".split(",");
			String[] geName = "Pl,Wjl,Nxbmz,Nxhb,Nxwxg,Yw,Zx,Total".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth * 2) + "></td><td" + subTitle(0, tWidth) + ">原始分</td><td"
						+ subTitle(0, -1) + ">标准分</td></tr>";
				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, -1) + ">" + gcName[i] + "</td><td" + subValue(0, -1) + ">"
							+ map.get(geName[i] + "_o") + "</td>" + "<td" + subValue(0, -1) + ">"
							+ map.get(geName[i] + "_s") + "</td></tr>";
				}
				strResult[1] += "<tr><td" + subTitle(0, -1) + ">情况</td><td colspan='2'" + subValue(0, -1) + ">"
						+ map.get("total_a") + "</td></tr>";

				strResult[1] += "</table>";
			}

			switch (String.valueOf(map.get("total_a"))) {
			case "较差":
			case "差":
			case "严重":
			case "非常严重":
				strResult[3] = "*";
				strResult[4] = "异常";
				break;
			default:
				strResult[3] = "0";
				strResult[4] = String.valueOf(map.get("total_a"));
				break;
			/*
			 * case "较差": strResult[3] = "1"; strResult[4] =
			 * String.valueOf(map.get("total_a")); break; case "差": strResult[3] = "2";
			 * strResult[4] = String.valueOf(map.get("total_a")); break; case "严重":
			 * strResult[3] = "3"; strResult[4] = String.valueOf(map.get("total_a")); break;
			 * case "非常严重": strResult[3] = "4"; strResult[4] =
			 * String.valueOf(map.get("total_a")); break; default: strResult[3] = "0";
			 * strResult[4] = String.valueOf(map.get("total_a")); break;
			 */
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 八十、女性性满意度指数Spdf
	private String[] GetSpdfReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "频率(INF),无交流(NCO),女性不满足(DISM),女性回避(AVF),女性无性感(NSF),阴道痉挛(VAG),缺乏性快感(PANORG),总分(ZF)"
					.split(",");
			String[] geName = "Pl,Wjl,Nxbmz,Nxhb,Nxwxg,Ydjl,Qfxkl,Total".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth * 2) + "></td><td" + subTitle(0, tWidth) + ">原始分</td><td"
						+ subTitle(0, -1) + ">标准分</td></tr>";
				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, -1) + ">" + gcName[i] + "</td><td" + subValue(0, -1) + ">"
							+ map.get(geName[i] + "_o") + "</td>" + "<td" + subValue(0, -1) + ">"
							+ map.get(geName[i] + "_s") + "</td></tr>";
				}
				strResult[1] += "<tr><td" + subTitle(0, -1) + ">情况</td><td colspan='2'" + subValue(0, -1) + ">"
						+ map.get("total_a") + "</td></tr>";

				strResult[1] += "</table>";
			}

			switch (String.valueOf(map.get("total_a"))) {
			case "较差":
			case "差":
			case "严重":
			case "非常严重":
				strResult[3] = "*";
				strResult[4] = "异常";
				break;
			default:
				strResult[3] = "0";
				strResult[4] = String.valueOf(map.get("total_a"));
				break;
			/*
			 * case "较差": strResult[3] = "1"; strResult[4] =
			 * String.valueOf(map.get("total_a")); break; case "差": strResult[3] = "2";
			 * strResult[4] = String.valueOf(map.get("total_a")); break; case "严重":
			 * strResult[3] = "3"; strResult[4] = String.valueOf(map.get("total_a")); break;
			 * case "非常严重": strResult[3] = "4"; strResult[4] =
			 * String.valueOf(map.get("total_a")); break; default: strResult[3] = "0";
			 * strResult[4] = String.valueOf(map.get("total_a")); break;
			 */
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 八十一、生存质量测定量表Whoqol CE ，比较特殊，需要传入原始题目选项
	private String[] GetWhoqolReport(Map<String, Object> map, String vAnswerString) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String strGc1 = "Ⅰ.生理领域,　1.疼痛与不适,　2.精力与疲倦,　3.睡眠与休息,Ⅱ.心理领域,　4.积极感受,　5.思想、学习、记忆和注意力,　6.自尊,　7.身材与相貌,　8.消极感受,"
					+ "Ⅲ.独立性领域,　9.行动能力,　10.日常生活能力,　11.对药物及医疗手段的依赖性,　12.工作能力,Ⅳ.社会关系领域,　13.个人关系,　14.所需社会支持的满意度,　15.性生活,"
					+ "Ⅴ.环境领域,　16.社会安全保障,　17.住房环境,　18.经济来源,　19.医疗服务与社会保障；获取途径与质量,　20.获取新信息、知识、技能的机会,　21.休闲娱乐活动的参与机会与参与程度,"
					+ "　22.环境条件(污染/噪声/交通/气候),　23.交通条件,Ⅵ.精神支柱/宗教/个人信仰,总体健康和生存质量";
			String[] gcName1 = strGc1.split(",");

			String strGd1 = "Ⅰ.PHYS,　1.疼痛与不适,　2.精力与疲倦,　3.睡眠与休息,Ⅱ.PSYCH,　4.积极感受,　5.思想、学习、记忆和注意力,　6.自尊,　7.身材与相貌,　8.消极感受,"
					+ "Ⅲ.IND,　9.行动能力,　10.日常生活能力,　11.对药物及医疗手段的依赖性,　12.工作能力,Ⅳ.SOCIL,　13.个人关系,　14.所需社会支持的满意度,　15.性生活,"
					+ "Ⅴ.ENVIR,　16.社会安全保障,　17.住房环境,　18.经济来源,　19.医疗服务与社会保障；获取途径与质量,　20.获取新信息、知识、技能的机会,　21.休闲娱乐活动的参与机会与参与程度,"
					+ "　22.环境条件(污染/噪声/交通/气候),　23.交通条件,Ⅵ.DOM6,总体健康和生存质量";
			String[] gdName1 = strGc1.split(",");
			String strGe1 = "Physiology,Pain,Energy,Sleep,Psychology,Feel,Think,Esteem,Body,Neg,Independence,Mobile,Active,Medic,Work,Society,Rela,Supp,Sex,Environment,"
					+ "Safe,Home,Fina,Serve,Info,Leisure,Envi,Traffic,Spirit,Total";
			String[] geName1 = strGe1.toLowerCase().split(",");

			String[] gcName2 = "家庭摩擦,食欲".split(",");
			String[] gsName2 = "根本不影响,很少影响,影响(一般),有比较大影响,有极大影响,很差,差,不好也不差,好,很好".split(",");
			String[] gvName1 = {};
			switch (g_CorE) {
			case 1:
				gvName1 = gcName1;
				break;
			case 2:
				gvName1 = gdName1;
				break;
			}

			if (g_inblFactor) {
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth * 4) + ">领域及因素</td><td" + subTitle(0, tWidth)
						+ ">原始分</td><td" + subTitle(0, -1) + ">标准分</td></tr>";
				for (i = 0; i < gcName1.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, -1) + ">" + gvName1[i] + "</td><td" + subValue(0, -1) + ">"
							+ map.get(geName1[i] + "_o") + "</td>" + "<td" + subValue(0, -1) + ">"
							+ map.get(geName1[i] + "_s") + "</td></tr>";
				}

				// String[] strAnswer = vAnswerString.split("@@");

				// ************************************************************************
				int intI;
				String strAnswer_c_Temp = vAnswerString.replaceAll("@", "0@@");
				String[] strAnswer = strAnswer_c_Temp.split("@@");
				if (strAnswer.length > 1) {
					for (intI = 1; intI < strAnswer.length; intI++) {
						strAnswer[intI] = strAnswer[intI].trim();
					}
				}
				// ************************************************************************

				if (strAnswer.length == 2) {
					String[] sAnswer = strAnswer[0].split("\\|");
					strResult[1] += "<tr><td colspan='3'" + subValue(0, -1) + ">附加题目</td></tr>";
					for (i = 0; i < gcName2.length; i++) {
						strResult[1] += "<tr><td" + subTitle(0, -1) + ">" + gcName2[i] + "</td><td colspan='2'"
								+ subValue(0, -1) + ">" + gsName2[i * 5 + Integer.valueOf(sAnswer[100 + i]) - 1]
								+ "</td></tr>";
					}
				}

				strResult[1] += "<tr><td" + subTitle(0, -1) + ">自我总评</td><td colspan='2'" + subValue(0, -1) + ">"
						+ strAnswer[1] + "</td></tr>";

				strResult[1] += "</table>";
			}

			strResult[3] = "0";
			strResult[4] = "";

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 八十二、纽芬兰纪念大学幸福度Munsh
	private String[] GetMunshReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "正性情感,负性情感,一般正性体验,一般负性体验,总幸福度".split(",");
			String[] gdName = "PA,NA,PE,NE,总幸福度".split(",");
			String[] geName = "Zxqg,Fxqg,Ybzxty,Ybfxty,Total".toLowerCase().split(",");

			String[] gvName = {};
			switch (g_CorE) {
			case 1:
				gvName = gcName;
				break;
			case 2:
				gvName = gdName;
				break;
			}

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth * 2) + ">" + gvName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i] + "_o") + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			if (String.valueOf(map.get("total_d")).split("\\.")[2].equals("1")) {
				strResult[3] = "*";
				strResult[4] = "幸福度评价很低，对生活不满意。";
			} else {
				strResult[3] = "0";
				strResult[4] = "正常";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 八十三、Conners简明症状问卷(Connts)
	private String[] GetConntsReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			String gcName = "总分";
			String geName = "Total_o".toLowerCase();

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName + "</td><td" + subValue(0, -1) + ">"
						+ map.get(geName) + "</td></tr>";

				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			if (String.valueOf(map.get("total_d")).split("\\.")[2].equals("2")) {
				strResult[3] = "*";
				strResult[4] = "差";
			} else {
				strResult[3] = "0";
				strResult[4] = "正常";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 八十四、Conners教师用量表(Connt)
	private String[] GetConntReport(Map<String, Object> map, int vSex, float vAge) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i, j;
			String strSD = "";

			String[] gcName = "品行问题,多动问题,不注意-被动,多动指数".split(",");
			String[] geName = "Pxwt,Ddwt,Bzybd,Ddzs".toLowerCase().split(",");

			// 均分标准差，按年龄
			if (vSex == 1) // 男
			{
				if (vAge < 6) {
					strSD = "0.45,0.80,0.79,0.89,0.92,1.00,0.81,0.96";
				} else if (6 <= vAge && vAge < 9) {
					strSD = "0.32,0.43,0.60,0.65,0.76,0.74,0.58,0.61";
				} else if (9 <= vAge && vAge < 12) {
					strSD = "0.50,0.66,0.70,0.78,0.85,0.73,0.67,0.65";
				} else if (12 <= vAge && vAge < 15) {
					strSD = "0.23,0.38,0.41,0.49,0.71,0.63,0.44,0.43";
				} else {
					strSD = "0.22,0.37,0.34,0.44,0.68,0.67,0.41,0.45";
				}
			} else // 女
			{
				if (vAge < 6) {
					strSD = "0.53,0.68,0.69,0.56,0.72,0.71,0.74,0.67";
				} else if (6 <= vAge && vAge < 9) {
					strSD = "0.28,0.37,0.28,0.38,0.47,0.64,0.36,0.45";
				} else if (9 <= vAge && vAge < 12) {
					strSD = "0.28,0.49,0.38,0.51,0.49,0.53,0.38,0.48";
				} else if (12 <= vAge && vAge < 15) {
					strSD = "0.15,0.23,0.19,0.27,0.32,0.42,0.18,0.24";
				} else {
					strSD = "0.33,0.68,0.32,0.63,0.45,0.47,0.36,0.62";
				}
			}

			String[] SD = strSD.split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">指标</td><td" + subTitle(0, oWidth / 2 * 3)
						+ ">平均分</td><td" + subTitle(0, tWidth + oWidth / 2) + ">均分与标准差</td>" + "<td"
						+ subTitle(0, tWidth) + ">指标</td><td" + subTitle(0, oWidth / 2 * 3) + ">平均分</td><td"
						+ subTitle(0, -1) + ">均分与标准差</td></tr>";
				for (i = 0; i < gcName.length; i = i + 2) {
					strResult[1] += "<tr>";
					for (j = 0; j < 2; j++) {
						String gsName = SD[i * 2 + j * 2] + "±" + SD[i * 2 + j * 2 + 1]; // 均分标准差
						strResult[1] += "<td" + subTitle(0, -1) + ">" + gcName[i + j] + "</td><td" + subValue(0, -1)
								+ ">" + map.get(geName[i + j] + "_ave") + "</td>" + "<td" + subValue(0, -1) + ">"
								+ gsName + "</td>";
					}
					strResult[1] += "</tr>";
				}

				strResult[1] += "</table>";
			}

			String strCode = "";
			for (i = 0; i < gcName.length; i++) {
				if (map.get(geName[i] + "_d").toString().length() > 0) {
					strCode += map.get(geName[i] + "_d") + "|";
				}
			}
			if (strCode.length() > 0) {
				strCode = strCode.substring(0, strCode.length() - 1);
			}

			strResult[2] = strCode;

			for (i = 0; i < gcName.length; i++) {
				if (String.valueOf(map.get(geName[i] + "_d")).split("\\.")[2].equals("1")) {
					strResult[3] = "*";
					strResult[4] += gcName[i].toString() + "异常" + "，";
				}
			}

			if (strResult[4].length() > 0) {
				strResult[4] = strResult[4].substring(0, strResult[4].length() - 1);
			} else {
				strResult[3] = "0";
				strResult[4] += "正常";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 八十五、儿童孤独症家长评定量表(Abc)
	private String[] GetAbcReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			String gcName = "总分";
			String geName = "Total_o".toLowerCase();

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName + "</td><td" + subValue(0, -1) + ">"
						+ map.get(geName) + "</td></tr>";

				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			switch (String.valueOf(map.get("total_d")).split("\\.")[2]) {
			case "1":
				strResult[3] = "0";
				strResult[4] = "正常";
				break;
			case "2":
				strResult[3] = "1";
				strResult[4] = "可疑的孤独症表现";
				break;
			case "3":
				strResult[3] = "2";
				strResult[4] = "明显的孤独症症状";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 八十六、儿童期孤独症评定量表(Cars)
	private String[] GetCarsReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			String gcName = "总分";
			String geName = "Total_o".toLowerCase();
			// 因子得分
			if (g_inblFactor) {
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";
				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName + "</td><td" + subValue(0, -1) + ">"
						+ map.get(geName) + "</td></tr>";
				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			switch (String.valueOf(map.get("total_d")).split("\\.")[2]) {
			case "1":
				strResult[3] = "0";
				strResult[4] = "正常";
				break;
			case "2":
				strResult[3] = "1";
				strResult[4] = "轻中度";
				break;
			case "3":
				strResult[3] = "2";
				strResult[4] = "严重";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 八十七、父母养育方式评价量表(Embu)
	private String[] GetEmbuReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "因子I,因子II,因子III,因子IV,因子V,因子VI".split(",");
			String[] gsName1 = "51.54±8.89,15.84±3.98,20.92±3.66,9.82 ±3.83,8.27 ±2.40,12.43±3.12".split(",");
			String[] gsName2 = "55.71±9.31,36.42±6.02,11.47±3.26,11.13±2.84,9.99 ±3.81".split(",");

			// vMode=3代表父母一起答题，目前软件不支持单方答题
			int vMode = 3;

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";
				switch (vMode) {
				case 1: // 父亲
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + oSpace + "</td><td" + subTitle(0, tWidth)
							+ ">父亲</td><td" + subTitle(0, -1) + ">均分标准差</td></tr>";
					for (i = 0; i < gsName1.length; i++) {
						strResult[1] += "<tr><td" + subTitle(0, -1) + ">" + gcName[i] + "</td>" + "<td"
								+ subValue(0, -1) + ">" + map.get("father" + String.valueOf(i + 1) + "_o") + "</td>"
								+ "<td" + subValue(0, -1) + ">" + gsName1[i] + "</td></tr>";
					}
					break;
				case 2: // 母亲
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + oSpace + "</td><td" + subTitle(0, tWidth)
							+ ">母亲</td><td" + subTitle(0, -1) + ">均分标准差</td></tr>";
					for (i = 0; i < gsName2.length; i++) {
						strResult[1] += "<tr><td" + subTitle(0, -1) + ">" + gcName[i] + "</td>" + "<td"
								+ subValue(0, -1) + ">" + map.get("mother" + String.valueOf(i + 1) + "_o") + "</td>"
								+ "<td" + subValue(0, -1) + ">" + gsName2[i] + "</td></tr>";
					}
					break;
				case 3: // 父母
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + oSpace + "</td><td" + subTitle(0, oWidth)
							+ ">父亲</td><td" + subTitle(0, oWidth * 3) + ">均分标准差</td>" + "<td" + subTitle(0, tWidth)
							+ ">" + oSpace + "</td><td" + subTitle(0, oWidth) + ">母亲</td><td" + subTitle(0, -1)
							+ ">均分标准差</td></tr>";
					for (i = 0; i < gsName1.length; i++) {
						strResult[1] += "<tr>";
						strResult[1] += "<td" + subTitle(0, -1) + ">" + gcName[i] + "</td>" + "<td" + subValue(0, -1)
								+ ">" + map.get("father" + String.valueOf(i + 1) + "_o") + "</td>" + "<td"
								+ subValue(0, -1) + ">" + gsName1[i] + "</td>";
						if (i <= gsName2.length - 1) {
							strResult[1] += "<td" + subTitle(0, -1) + ">" + gcName[i] + "</td>" + "<td"
									+ subValue(0, -1) + ">" + map.get("mother" + String.valueOf(i + 1) + "_o") + "</td>"
									+ "<td" + subValue(0, -1) + ">" + gsName2[i] + "</td>";
						} else {
							strResult[1] += "<td colspan='3'" + subValue(0, -1) + "></td>";
						}
						strResult[1] += "</tr>";
					}
					break;
				}
				strResult[1] += "</table>";
			}

			String strCode = "";
			for (i = 0; i < gsName1.length; i++) {
				if (map.get("father" + String.valueOf(i + 1) + "_d").toString().length() > 0) {
					strCode += map.get("father" + String.valueOf(i + 1) + "_d").toString() + "|";
				}
			}

			for (i = 0; i < gsName2.length; i++) {
				if (map.get("mother" + String.valueOf(i + 1) + "_d").toString().length() > 0) {
					strCode += map.get("mother" + String.valueOf(i + 1) + "_d").toString() + "|";
				}
			}

			if (strCode.length() > 0) {
				strCode = strCode.substring(0, strCode.length() - 1);
			}

			strResult[2] = strCode;

			strResult[3] = "0";
			strResult[4] = "";

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 八十八、青少年生活事件量表(Aslec)
	private String[] GetAslecReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "人际关系因子,学习压力因子,受惩罚因子,丧失因子,健康适应因子,其他".split(",");
			String[] geName = "Rjgx,Xxyl,Scf,Ss,Jksy,Other".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth * 2) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i] + "_o") + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			strResult[3] = "0";
			strResult[4] = "";

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 八十九、职业兴趣调查问卷(Zyqx)
	private String[] GetZyqxReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String strDoctorIdea = "";

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='90%' border='0'>" + "<tr><td"
						+ subTitle(0, -1) + ">最感兴趣的职业依次为</td></tr>";

				for (i = 1; i < 5; i++) {
					strResult[1] += "<tr><td" + subValue(0, -1) + ">" + tSpace + String.valueOf(i) + ". "
							+ map.get("job" + String.valueOf(i) + "_a") + "</td></tr>";
					strDoctorIdea += map.get("job" + String.valueOf(i) + "_a") + "，";
				}
				strResult[1] += "</table>";
			}

			// strResult[2] += m_Line;
			strResult[2] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";
			strResult[2] += "<tr><td" + subTitle(0, -1) + ">测评结果</td></tr>";
			strResult[2] += "<tr><td" + subValue(0, -1) + ">" + tSpace + strDoctorIdea
					+ "是最吸引你的。尽量从事这些职业，可以使你得到工作上的满足感。" + "</tr></td>";
			strResult[2] += "</table>";

			strResult[3] = "0";
			strResult[4] = "";

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 九十、霍兰德职业倾向问卷(Hldzyqx)
	private String[] GetHldzyqxReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "现实型,探索型,艺术型,社会型,管理型,常规型".split(",");
			String[] geName = "Xs,Ts,Ys,Sh,Gl,Cg".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i] + "_o") + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			String strCode = "";
			for (i = 1; i < 4; i++) {
				strCode += map.get("total" + String.valueOf(i) + "_d") + "|";
			}
			if (strCode.length() > 0) {
				strCode = strCode.substring(0, strCode.length() - 1);
			}

			strResult[2] = strCode;

			strResult[3] = "0";
			strResult[4] = "";

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 九十一、多动症诊断量表(Adhd)
	private String[] GetAdhdReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "注意力分散,多动或冲动,诊断结果".split(",");
			String[] geName = "Zyl_o,Dd_o,Total_a".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";
				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">指标</td><td" + subTitle(0, -1) + ">数目</td></tr>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, -1) + ">" + gcName[i] + "</td><td" + subValue(0, -1) + ">"
							+ map.get(geName[i]) + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			if (String.valueOf(map.get("total_a")).equals("正常类型")) {
				strResult[3] = "0";
				strResult[4] = "正常";
			} else {
				strResult[3] = "*";
				strResult[4] = String.valueOf(map.get("total_a"));
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 九十二、睡眠状况自评量表(Srss)
	private String[] GetSrssReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "总分,参考诊断".split(",");
			String[] geName = "Total_o,Total_a".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i]) + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			switch (String.valueOf(map.get("total_a"))) {
			case "睡眠状态正常者":
				strResult[3] = "0";
				strResult[4] = "睡眠状态正常";
				break;
			case "轻度睡眠问题":
				strResult[3] = "1";
				strResult[4] = "轻度睡眠问题";
				break;
			case "中度睡眠问题":
				strResult[3] = "2";
				strResult[4] = "中度睡眠问题";
				break;
			case "重度睡眠问题":
				strResult[3] = "3";
				strResult[4] = "重度睡眠问题";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 九十三、临床疗效总评量表(Cgi)
	private String[] GetCgiReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "病情严重程度(Sl),疗效总评(Gl),疗效指数(El)".split(",");
			String[] geName = "Sl,Gl,El".toLowerCase().split(",");
			String[] gsName = "分值范围0-7,分值范围0-7,分值范围0-4.00".split(",");

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth * 2) + ">" + gcName[i] + "</td><td"
							+ subValue(0, tWidth) + ">" + map.get(geName[i] + "_o") + "</td>" + "<td" + subTitle(0, -1)
							+ ">" + gsName[i] + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			strResult[3] = "0";
			strResult[4] = "";

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 九十四、3-7岁儿童气质问卷(Nyls)
	private String[] GetNylsReport(Map<String, Object> map, int vSex, float vAge) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i;

			String[][] strTwoA = { { "活动水平", "hdsp" }, { "节律性", "jlx" }, { "趋避性", "qbx" }, { "适应性", "syx" },
					{ "反应强度", "fyqd" }, { "情绪本质", "qxbz" }, { "坚持度", "jcd" }, { "注意分散度", "zyfsd" }, { "反应阀", "fyf" } };

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth * 2) + ">" + "测试结果" + "</td><td" + subTitle(0, tWidth)
						+ ">" + "因子得分" + "</td>" + "<td" + subTitle(0, -1) + ">" + "均分±标准差" + "</td></tr>";

				// 均分±标准差
				float[][] sngMinDivA;
				if (vSex == 1) // 男
				{
					if (vAge <= 3) {
						float[][] arrMinDiv = { { 4.03f, 0.86f }, { 4.58f, 0.85f }, { 4.64f, 0.93f }, { 5.05f, 0.78f },
								{ 3.97f, 0.87f }, { 4.58f, 0.63f }, { 3.99f, 0.57f }, { 4.4f, 0.72f },
								{ 3.26f, 0.85f } };
						sngMinDivA = arrMinDiv;
					} else if (3 < vAge && vAge <= 4) {
						float[][] arrMinDiv = { { 3.89f, 0.78f }, { 4.64f, 0.83f }, { 4.84f, 0.82f }, { 5.16f, 0.83f },
								{ 3.9f, 0.84f }, { 4.62f, 0.6f }, { 4.03f, 0.61f }, { 4.37f, 0.71f }, { 3.04f, 0.8f } };
						sngMinDivA = arrMinDiv;
					} else if (4 < vAge && vAge <= 5) {
						float[][] arrMinDiv = { { 3.92f, 0.79f }, { 4.49f, 0.82f }, { 5f, 0.86f }, { 5.25f, 0.74f },
								{ 3.73f, 0.81f }, { 4.58f, 0.63f }, { 4.06f, 0.58f }, { 4.35f, 0.73f },
								{ 3.25f, 0.7f } };
						sngMinDivA = arrMinDiv;
					} else if (5 < vAge && vAge <= 6) {
						float[][] arrMinDiv = { { 3.74f, 0.89f }, { 4.53f, 0.84f }, { 5.1f, 0.86f }, { 5.24f, 0.77f },
								{ 3.64f, 0.83f }, { 4.65f, 0.68f }, { 4.15f, 0.59f }, { 4.28f, 0.67f },
								{ 3.36f, 0.76f } };
						sngMinDivA = arrMinDiv;
					} else {
						float[][] arrMinDiv = { { 3.84f, 0.85f }, { 4.65f, 0.82f }, { 5.06f, 0.83f }, { 5.16f, 0.75f },
								{ 3.57f, 0.75f }, { 4.64f, 0.64f }, { 4.13f, 0.65f }, { 4.23f, 0.78f },
								{ 3.49f, 0.75f } };
						sngMinDivA = arrMinDiv;
					}
				} else // 女
				{
					if (vAge <= 3) {
						float[][] arrMinDiv = { { 3.98f, 0.83f }, { 4.63f, 0.85f }, { 4.8f, 0.89f }, { 5.12f, 0.75f },
								{ 4.04f, 0.85f }, { 4.79f, 0.62f }, { 4.04f, 0.61f }, { 4.5f, 0.75f },
								{ 3.04f, 0.8f } };
						sngMinDivA = arrMinDiv;
					} else if (3 < vAge && vAge <= 4) {
						float[][] arrMinDiv = { { 3.8f, 0.83f }, { 4.48f, 0.91f }, { 4.75f, 0.85f }, { 5.06f, 0.8f },
								{ 3.87f, 0.95f }, { 4.76f, 0.73f }, { 4.08f, 0.62f }, { 4.44f, 0.76f },
								{ 3.14f, 0.79f } };
						sngMinDivA = arrMinDiv;
					} else if (4 < vAge && vAge <= 5) {
						float[][] arrMinDiv = { { 3.6f, 0.89f }, { 4.49f, 0.89f }, { 5f, 0.81f }, { 5.16f, 0.7f },
								{ 3.6f, 0.8f }, { 4.7f, 0.64f }, { 4.08f, 0.61f }, { 4.58f, 0.72f }, { 3.1f, 0.72f } };
						sngMinDivA = arrMinDiv;
					} else if (5 < vAge && vAge <= 6) {
						float[][] arrMinDiv = { { 3.51f, 0.91f }, { 4.57f, 0.89f }, { 5.14f, 0.79f }, { 5.26f, 0.8f },
								{ 3.58f, 0.83f }, { 4.84f, 0.6f }, { 4.11f, 0.6f }, { 4.44f, 0.7f }, { 3.27f, 0.74f } };
						sngMinDivA = arrMinDiv;
					} else {
						float[][] arrMinDiv = { { 3.54f, 0.93f }, { 4.52f, 0.86f }, { 5.03f, 0.82f }, { 5.21f, 0.77f },
								{ 3.52f, 0.82f }, { 4.8f, 0.6f }, { 4.12f, 0.57f }, { 4.43f, 0.78f },
								{ 3.27f, 0.77f } };
						sngMinDivA = arrMinDiv;
					}
				}

				for (i = 0; i < strTwoA.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth * 2) + ">" + strTwoA[i][0] + "</td><td"
							+ subValue(0, tWidth) + ">" + map.get(strTwoA[i][1] + "_ave") + "</td>" + "<td"
							+ subValue(0, -1) + ">" + sngMinDivA[i][0] + "±" + String.valueOf(sngMinDivA[i][1])
							+ "</td></tr>";
				}

				// 诊断结果
				strResult[1] += "<tr><td" + subTitle(0, tWidth * 2) + ">" + "诊断结果：" + "</td><td" + subValue(0, tWidth)
						+ ">" + map.get("total_a") + "</td>" + "<td" + subValue(0, -1) + ">" + "</td></tr>";

				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			switch (String.valueOf(map.get("total_a"))) {
			case "易养型":
			case "中间型":
				strResult[3] = "0";
				strResult[4] = String.valueOf(map.get("total_a"));
				break;
			case "启动缓慢型":
			case "难养型":
				strResult[3] = "*";
				strResult[4] = String.valueOf(map.get("total_a"));
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 九十五、Rutter儿童行为父母问卷(Rutterp)
	private String[] GetRutterpReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "总分,N分,A分".split(",");
			String[] geName = "Total_o,N_o,A_o".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{

				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i]) + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			// 医生意见
			strResult[2] = String.valueOf(map.get("total_d"));

			switch (String.valueOf(map.get("total_d")).split("\\.")[2]) {
			case "1":
			case "2":
			case "3":
				strResult[3] = "*";
				strResult[4] = "异常";
				break;
			case "4":
				strResult[3] = "0";
				strResult[4] = "正常";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 九十六、Rutter儿童行为教师问卷(Ruttert)
	private String[] GetRuttertReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i = 0;
			String[] gcName = "总分,N分,A分".split(",");
			String[] geName = "Total_o,N_o,A_o".toLowerCase().split(",");

			if (g_inblFactor) // 因子得分
			{

				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < gcName.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + gcName[i] + "</td><td" + subValue(0, -1)
							+ ">" + map.get(geName[i]) + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			// 医生意见
			strResult[2] = String.valueOf(map.get("total_d"));

			switch (String.valueOf(map.get("total_d")).split("\\.")[2]) {
			case "1":
			case "2":
			case "3":
				strResult[3] = "*";
				strResult[4] = "异常";
				break;
			case "4":
				strResult[3] = "0";
				strResult[4] = "正常";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 九十七、儿童自我意识量表(Piersharris)
	private String[] GetPiersharrisReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i;
			String[] strCodeA = { "I", "II", "III", "IV", "V", "VI", "VII" };
			String[][] strNameA = { { "行为", "Xw", "11.97±2.97" }, { "智力与学校情况", "Zl", "8.89±3.27" },
					{ "躯体外貌与属性", "Qt", "6.40±2.81" }, { "焦虑", "Jl", "9.35±2.85" }, { "合群", "Hq", "8.49±2.20" },
					{ "幸福与满足", "Xf", "7.12±1.98" }, { "总分", "Total", "51.66±11.47" } };

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "" + "</td><td" + subTitle(0, tWidth * 2) + ">"
						+ "因子" + "</td>" + "<td" + subTitle(0, tWidth) + ">" + "原始分" + "</td>" + "<td" + subTitle(0, -1)
						+ ">" + "参考标准" + "</td></tr>";

				for (i = 0; i < strNameA.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + strCodeA[i] + "</td><td"
							+ subTitle(0, tWidth * 2) + ">" + strNameA[i][0] + "</td>" + "<td" + subValue(0, tWidth)
							+ ">" + map.get(strNameA[i][1].toLowerCase() + "_o") + "</td>" + "<td" + subValue(0, -1)
							+ ">" + strNameA[i][2] + "</td></tr>";
				}
				strResult[1] += "</table>";
			}
			// 医生意见
			strResult[2] = String.valueOf(map.get("total_d"));

			switch (String.valueOf(map.get("total_d")).split("\\.")[2]) {
			case "1":
			case "3":
				strResult[3] = "*";
				strResult[4] = "异常";
				break;
			case "2":
				strResult[3] = "0";
				strResult[4] = "正常";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 九十八、儿童感觉统合检核表(Etgj)
	private String[] GetEtgjReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i;

			String[] strCodeA = { "I", "II", "III", "IV", "V", "VI", "VII", "VIII", "IX" };
			String[][] strNameA = { { "前庭平衡和大脑双侧分化情况", "Qt" }, { "脑神经生理抑制困难", "Nsj" }, { "触觉防御", "Cj" },
					{ "发育运用障碍", "Fy" }, { "视觉空间和形态感觉情形", "Sj" }, { "重力（地心引力、姿势）不安全症", "Zl" }, { "学习和情绪状态", "Xx" },
					{ "对压力挫折敏感、自我形象不良", "Dyl" }, { "感觉统合整体评估", "Total" } };

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "" + "</td><td" + subTitle(0, tWidth * 3) + ">"
						+ "因子" + "</td>" + "<td" + subTitle(0, tWidth) + ">" + "原始分" + "</td>" + "<td" + subTitle(0, -1)
						+ ">" + "T分" + "</td></tr>";

				for (i = 0; i < strNameA.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + strCodeA[i] + "</td><td"
							+ subTitle(0, tWidth * 2) + ">" + strNameA[i][0] + "</td>" + "<td" + subValue(0, tWidth)
							+ ">" + map.get(strNameA[i][1].toLowerCase() + "_o") + "</td>" + "<td" + subValue(0, -1)
							+ ">" + map.get(strNameA[i][1].toLowerCase() + "_t") + "</td></tr>";
				}
				strResult[1] += "</table>";
			}

			// 医生意见
			String strCode = "";
			for (i = 0; i < strNameA.length; i++) {
				strCode += map.get(strNameA[i][1].toLowerCase() + "_d") + "|";
			}

			if (strCode.length() > 0) {
				strCode = strCode.substring(0, strCode.length() - 1);
			}
			strResult[2] = strCode;

			switch (String.valueOf(map.get("total_d")).split("\\.")[2]) {
			case "1":
				strResult[3] = "0";
				strResult[4] = "正常";
				break;
			case "2":
				strResult[3] = "1";
				strResult[4] = "感觉统合功能轻度失调";
				break;
			case "3":
				strResult[3] = "2";
				strResult[4] = "感觉统合功能严重失调";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 九十九、儿童社会期望量表(Csd)
	private String[] GetCsdReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "总分" + "</td><td" + subValue(0, -1) + ">"
						+ map.get("total_o") + "</td></tr>";

				strResult[1] += "</table>";
			}

			strResult[3] = "0";
			strResult[4] = "";

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百、儿童社交焦虑量表(Sasc)
	private String[] GetSascReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "总分" + "</td><td" + subValue(0, -1) + ">"
						+ map.get("total_o") + "</td></tr>";

				strResult[1] += "</table>";
			}

			// 医生意见
			strResult[2] = String.valueOf(map.get("total_d"));

			switch (String.valueOf(map.get("total_d")).split("\\.")[2]) {
			case "1":
				strResult[3] = "0";
				strResult[4] = "无明显社交焦虑现象";
				break;
			case "2":
				strResult[3] = "1";
				strResult[4] = "存在可疑的社交焦虑现象";
				break;
			case "3":
				strResult[3] = "2";
				strResult[4] = "存在明显社交焦虑现象";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百零一、抑郁状态问卷(Dis)
	private String[] GetDisReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "总分" + "</td><td" + subValue(0, -1) + ">"
						+ map.get("total_o") + "</td></tr>";
				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "诊断结果" + "</td><td" + subValue(0, -1) + ">"
						+ map.get("total_a") + "</td></tr>";

				strResult[1] += "</table>";
			}

			// 医生意见
			strResult[2] = String.valueOf(map.get("total_d"));

			switch (String.valueOf(map.get("total_a"))) {
			case "无抑郁症状":
				strResult[3] = "0";
				strResult[4] = "无抑郁症状";
				break;
			case "有（轻度）抑郁症状":
				strResult[3] = "1";
				strResult[4] = "有（轻度）抑郁症状";
				break;
			case "有（中度）抑郁症状":
				strResult[3] = "2";
				strResult[4] = "有（中度）抑郁症状";
				break;
			case "有（重度）抑郁症状":
				strResult[3] = "3";
				strResult[4] = "有（重度）抑郁症状";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百零二、自杀态度问卷(Qsa)
	private String[] GetQsaReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i;

			String[][] strNameA = { { "对自杀行为性质的认识", "Xw" }, { "对自杀者的态度", "Zsz" }, { "对自杀者家属的态度", "Js" },
					{ "对安乐死的态度", "Als" } };

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "因子" + "</td><td" + subTitle(0, tWidth) + ">"
						+ "得分" + "</td>" + "<td" + subTitle(0, tWidth * 2) + ">" + "诊断结果" + "</td></tr>";

				for (i = 0; i < strNameA.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + strNameA[i][0] + "</td><td"
							+ subValue(0, tWidth) + ">" + map.get(strNameA[i][1].toLowerCase() + "_ave") + "</td>"
							+ "<td" + subValue(0, tWidth * 2) + ">" + map.get(strNameA[i][1].toLowerCase() + "_a")
							+ "</td></tr>";
				}

				// 总分
				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "总分" + "</td><td" + subValue(0, -1) + ">"
						+ map.get("total_o") + "</td></tr>";

				strResult[1] += "</table>";
			}

			// 预警，因为整体不好判断，所以暂定所有四个因子均有问题才异常
			int intTemp = 0;
			for (i = 0; i < strNameA.length; i++) {
				if (Float.valueOf(String.valueOf(map.get(strNameA[i][1].toLowerCase() + "_ave"))) <= 2.5f) {
					intTemp += 1;
				}
			}
			if (intTemp == 4) {
				strResult[3] = "*";
				strResult[4] = "自杀态度异常";
			} else {
				strResult[3] = "0";
				strResult[4] = "正常";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百零三、学龄前儿童活动调查表(Psai)
	private String[] GetPsaiReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "总分" + "</td><td" + subValue(0, -1) + ">"
						+ map.get("total_o") + "</td></tr>";

				strResult[1] += "</table>";
			}

			// 医生意见
			strResult[2] = String.valueOf(map.get("total_d"));

			if (String.valueOf(map.get("total_d")).split("\\.")[1].equals("1")) {
				if (String.valueOf(map.get("total_d")).split("\\.")[2].equals("1")) {
					strResult[3] = "*";
					strResult[4] = "男性化程度不够";
				} else {
					strResult[3] = "0";
					strResult[4] = "正常";
				}
			} else {
				if (String.valueOf(map.get("total_d")).split("\\.")[2].equals("3")) {
					strResult[3] = "*";
					strResult[4] = "女性化程度不够";
				} else {
					strResult[3] = "0";
					strResult[4] = "正常";
				}
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百零四、4-8个月婴儿气质问卷(Cts48m)
	private String[] GetCts48mReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i;

			String[][] strNameA = { { "活动水平", "Hdsp" }, { "节律性", "Jlx" }, { "趋避性", "Qbx" }, { "适应性", "Syx" },
					{ "反应强度", "Fyqd" }, { "心境", "Xg" }, { "持久度", "Cjd" }, { "注意分散", "Zyfs" }, { "反应阀", "Fyf" } };
			// 均分±标准差
			float[][] sngMinDivA = { { 3.69f, 0.62f }, { 3.09f, 0.7f }, { 2.91f, 0.81f }, { 2.94f, 0.69f },
					{ 3.59f, 0.66f }, { 3.37f, 0.7f }, { 3.21f, 0.78f }, { 2.91f, 0.66f }, { 3.88f, 0.68f } };

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "因子" + "</td><td" + subTitle(0, tWidth) + ">"
						+ "得分" + "</td>" + "<td" + subTitle(0, tWidth) + ">" + "均分±标准差" + "</td></tr>";

				for (i = 0; i < strNameA.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + strNameA[i][0] + "</td><td"
							+ subValue(0, tWidth) + ">" + map.get(strNameA[i][1].toLowerCase() + "_ave") + "</td>"
							+ "<td" + subValue(0, tWidth) + ">" + String.valueOf(sngMinDivA[i][0]) + "±"
							+ String.valueOf(sngMinDivA[i][1]) + "</td></tr>";
				}

				// 诊断结果
				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "诊断结果：" + "</td><td" + subValue(0, -1) + ">"
						+ map.get("total_a") + "</td></tr>";

				strResult[1] += "</table>";
			}

			// 医生意见
			String strCode = "";
			for (i = 0; i < strNameA.length; i++) {
				strCode += map.get(strNameA[i][1].toLowerCase() + "_d") + "|";
			}

			// 这里比较特殊
			// ******************************************************
			strCode += map.get("total_d") + "|";
			// ******************************************************
			if (strCode.length() > 0) {
				strCode = strCode.substring(0, strCode.length() - 1);
			}

			strResult[2] = strCode;

			switch (String.valueOf(map.get("total_a"))) {
			case "易养型":
			case "中间型":
				strResult[3] = "0";
				strResult[4] = String.valueOf(map.get("total_a"));
				break;
			case "启动缓慢型":
			case "难养型":
				strResult[3] = "*";
				strResult[4] = String.valueOf(map.get("total_a"));
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百零五、1-3岁婴幼儿气质问卷(Cts13y)
	private String[] GetCts13yReport(Map<String, Object> map, int vSex) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i;

			String[][] strNameA = { { "活动水平", "Hdsp" }, { "节律性", "Jlx" }, { "趋避性", "Qbx" }, { "适应性", "Syx" },
					{ "反应强度", "Fyqd" }, { "心境", "Xg" }, { "持久度", "Cjd" }, { "注意分散", "Zyfs" }, { "反应阀", "Fyf" } };

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "因子" + "</td><td" + subTitle(0, tWidth) + ">"
						+ "得分" + "</td>" + "<td" + subTitle(0, tWidth) + ">" + "均分±标准差" + "</td></tr>";

				// 均分标准差
				float[][] sngMinDivA;
				if (vSex == 1) // 男
				{
					float[][] arrMinDivA = { { 3.7f, 0.58f }, { 2.99f, 0.59f }, { 3.26f, 0.81f }, { 3.39f, 0.59f },
							{ 3.94f, 0.68f }, { 3.09f, 0.6f }, { 3.16f, 0.73f }, { 3.73f, 0.59f }, { 3.35f, 0.64f } };
					sngMinDivA = arrMinDivA;
				} else // 女
				{
					float[][] arrMinDivA = { { 3.62f, 0.6f }, { 2.96f, 0.6f }, { 3.38f, 0.81f }, { 3.31f, 0.59f },
							{ 3.89f, 0.66f }, { 3.06f, 0.57f }, { 3.18f, 0.68f }, { 3.81f, 0.57f }, { 3.31f, 0.64f } };
					sngMinDivA = arrMinDivA;
				}

				for (i = 0; i < strNameA.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + strNameA[i][0] + "</td><td"
							+ subValue(0, tWidth) + ">" + map.get(strNameA[i][1].toLowerCase() + "_ave") + "</td>"
							+ "<td" + subValue(0, tWidth) + ">" + String.valueOf(sngMinDivA[i][0]) + "±"
							+ String.valueOf(sngMinDivA[i][1]) + "</td></tr>";
				}

				// 诊断结果
				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "诊断结果：" + "</td><td" + subValue(0, -1) + ">"
						+ map.get("total_a") + "</td></tr>";

				strResult[1] += "</table>";
			}

			// 医生意见
			String strCode = "";
			for (i = 0; i < strNameA.length; i++) {
				strCode += map.get(strNameA[i][1].toLowerCase() + "_d") + "|";
			}

			// 这里比较特殊
			// ******************************************************
			strCode += map.get("total_d") + "|";
			// ******************************************************
			if (strCode.length() > 0) {
				strCode = strCode.substring(0, strCode.length() - 1);
			}

			strResult[2] = strCode;

			switch (String.valueOf(map.get("total_a"))) {
			case "易养型":
			case "中间型":
				strResult[3] = "0";
				strResult[4] = String.valueOf(map.get("total_a"));
				break;
			case "启动缓慢型":
			case "难养型":
				strResult[3] = "*";
				strResult[4] = String.valueOf(map.get("total_a"));
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百零六、2-3岁儿童行为量表(Cbcl2to3)，量表特殊需要传入原始题目选项
	private String[] GetCbcl2to3Report(Map<String, Object> map, String vAnswerString) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i;

			String[][] strNameA = { { "社会退缩", "Shts" }, { "忧郁", "Yy" }, { "睡眠问题", "Smwt" }, { "躯体诉述", "Qtss" },
					{ "攻击", "Gj" }, { "破坏", "Ph" } };

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>" + "<tr><td"
						+ subTitle(0, tWidth) + ">" + "测试结果" + "</td>" + "<td" + subTitle(0, -1) + ">" + ""
						+ "</td></tr>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "因子名称" + "</td><td" + subTitle(0, -1) + ">"
						+ "因子得分" + "</td></tr>";

				for (i = 0; i < strNameA.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + strNameA[i][0] + "</td>" + "<td"
							+ subValue(0, -1) + ">" + map.get(strNameA[i][1].toLowerCase() + "_o") + "</td></tr>";
				}

				// String[] strSubA = vAnswerString.split("@@"); //100题，其他问题

				// ************************************************************************
				int intI;
				// 转换回原来格式
				String strTemp = vAnswerString.replaceAll("\\|@", "@@");
				String[] strSubA = strTemp.split("@@");
				if (strSubA.length > 1) {
					for (intI = 1; intI < strSubA.length; intI++) {
						strSubA[intI] = strSubA[intI].trim();
					}
				}
				// ************************************************************************

				if (strSubA.length > 1) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "其他问题" + "</td>" + "<td" + subValue(0, -1)
							+ ">" + strSubA[1] + "</td></tr>";
				}

				strResult[1] += "</table>";
			}

			// 医生意见
			String strCode = "";
			for (i = 0; i < strNameA.length; i++) {
				strCode += map.get(strNameA[i][1].toLowerCase() + "_d") + "|";
			}
			if (strCode.length() > 0) {
				strCode = strCode.substring(0, strCode.length() - 1);
			}

			strResult[2] = strCode;

			// 预警，实在是不好评价，后面再研究
			strResult[3] = "0";
			strResult[4] = "";

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百零七、Sarason考试焦虑量表(Sarasontas)
	private String[] GetSarasontasReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "总粗分" + "</td><td" + subValue(0, -1) + ">"
						+ map.get("total_o") + "</td></tr>";

				strResult[1] += "</table>";
			}

			// 医生意见
			strResult[2] = String.valueOf(map.get("total_d"));

			switch (String.valueOf(map.get("total_d")).split("\\.")[2]) {
			case "1":
				strResult[3] = "0";
				strResult[4] = "正常或较低水平考试焦虑";
				break;
			case "2":
				strResult[3] = "1";
				strResult[4] = "中度考试焦虑";
				break;
			case "3":
				strResult[3] = "2";
				strResult[4] = "重度考试焦虑";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百零八、婴儿-初中生社会生活能力量表(Sm)
	private String[] GetSmReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i;

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "因子" + "</td><td" + subTitle(0, tWidth) + ">"
						+ "粗分" + "</td>" + "<td" + subTitle(0, tWidth) + ">" + "标准分" + "</td></tr>";

				String[][] strNameA = { { "独立生活", "Dlsh" }, { "运动", "Yd" }, { "作业操作", "Zycz" }, { "交往", "Jw" },
						{ "集体活动", "Jthd" }, { "自我管理", "Zwgl" } };
				for (i = 0; i < strNameA.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + strNameA[i][0] + "</td><td"
							+ subValue(0, tWidth) + ">" + map.get(strNameA[i][1].toLowerCase() + "_o") + "</td>" + "<td"
							+ subValue(0, tWidth) + ">" + "" + "</td></tr>";
				}

				// 诊断结果
				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "总分" + "</td><td" + subValue(0, -1) + ">"
						+ map.get("total_o") + "</td>" + "<td" + subValue(0, tWidth) + ">" + map.get("total_s")
						+ "</td></tr>";

				strResult[1] += "</table>";

			}

			// 医生意见
			strResult[2] = String.valueOf(map.get("total_d"));

			switch (String.valueOf(map.get("total_d")).split("\\.")[2]) {
			case "1":
				strResult[3] = "4";
				strResult[4] = "极重度";
			case "2":
				strResult[3] = "4";
				strResult[4] = "重度";
				break;
			case "3":
				strResult[3] = "3";
				strResult[4] = "中度";
				break;
			case "4":
				strResult[3] = "2";
				strResult[4] = "轻度";
				break;
			case "5":
				strResult[3] = "1";
				strResult[4] = "边缘";
				break;
			case "6":
				strResult[3] = "0";
				strResult[4] = "正常";
				break;
			case "7":
				strResult[3] = "0";
				strResult[4] = "高常";
				break;
			case "8":
				strResult[3] = "0";
				strResult[4] = "优秀";
				break;
			case "9":
				strResult[3] = "0";
				strResult[4] = "非常优秀";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百零九、学习障碍儿童筛查量表(Xxza)
	private String[] GetXxzaReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i;

			String[][] strNameA = { { "言语性LD筛查", "Yy" }, { "非言语性LD筛查", "Fyy" } };

			if (g_inblFactor) // 因子得分
			{

				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				for (i = 0; i < strNameA.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth * 2) + ">" + strNameA[i][0] + "</td><td"
							+ subValue(0, -1) + ">" + map.get(strNameA[i][1].toLowerCase() + "_o") + "</td></tr>";
				}

				// 总分
				strResult[1] += "<tr><td" + subTitle(0, tWidth * 2) + ">" + "总分" + "</td><td" + subValue(0, -1) + ">"
						+ map.get("total_o") + "</td></tr>";
				strResult[1] += "</table>";
			}

			// 医生意见
			String strCode = "";
			for (i = 0; i < strNameA.length; i++) {
				strCode += map.get(strNameA[i][1].toLowerCase() + "_d") + "|";
			}

			if (strCode.length() > 0) {
				strCode = strCode.substring(0, strCode.length() - 1);
			}

			strResult[2] = strCode;

			for (i = 0; i < strNameA.length; i++) {
				if (String.valueOf(map.get(strNameA[i][1].toLowerCase() + "_d")).split("\\.")[1].equals("1")) {
					if (String.valueOf(map.get(strNameA[i][1].toLowerCase() + "_d")).split("\\.")[2].equals("1")) {
						strResult[3] = "*";
						strResult[4] += "言语有障碍" + "，";
					}
				} else {
					if (String.valueOf(map.get(strNameA[i][1].toLowerCase() + "_d")).split("\\.")[2].equals("1")) {
						strResult[3] = "*";
						strResult[4] += "非言语有障碍" + "，";
					}
				}
			}

			if (strResult[4].length() > 0) {
				strResult[4] = strResult[4].substring(0, strResult[4].length() - 1);
			} else {
				strResult[3] = "0";
				strResult[4] = "正常";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百十、中国中学生心理健康检测(Xljk)
	// ---table_uuid: 22B9ECA4-08CD-4BAE-83EB-0ABBA63F5BE5
	private String[] GetXljkReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i;

			String[][] strNameA = { { "强迫症状", "Qbzz" }, { "偏执", "Pz" }, { "敌对", "Dd" }, { "人际关系紧张与敏感", "Rjgx" },
					{ "抑郁", "Yy" }, { "焦虑", "Jl" }, { "学习压力", "Xxyl" }, { "适应不良", "Sybl" }, { "情绪不平衡", "Qx" },
					{ "心理不平衡", "Xl" }, { "总分", "Total" } };

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "因子" + "</td><td" + subTitle(0, tWidth) + ">"
						+ "得分" + "</td>" + "<td" + subTitle(0, tWidth) + ">" + "平均分" + "</td><td" + subTitle(0, tWidth)
						+ ">" + "参考诊断" + "</td></tr>";

				for (i = 0; i < strNameA.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + strNameA[i][0] + "</td><td"
							+ subValue(0, tWidth) + ">" + map.get(strNameA[i][1].toLowerCase() + "_o") + "</td>" + "<td"
							+ subValue(0, tWidth) + ">" + map.get(strNameA[i][1].toLowerCase() + "_ave") + "</td><td"
							+ subValue(0, tWidth) + ">" + map.get(strNameA[i][1].toLowerCase() + "_a") + "</td></tr>";
				}

				strResult[1] += "</table>";
			}

			// 医生意见
			String strCode = "";
			for (i = 0; i < strNameA.length; i++) {
				strCode += map.get(strNameA[i][1].toLowerCase() + "_d") + "|";
			}

			if (strCode.length() > 0) {
				strCode = strCode.substring(0, strCode.length() - 1);
			}

			strResult[2] = strCode;

			switch (String.valueOf(map.get("total_a"))) {
			case "无":
				strResult[3] = "0";
				strResult[4] = "没有心理健康问题";
				break;
			case "轻度":
				strResult[3] = "1";
				strResult[4] = "轻度心理健康问题";
				break;
			case "中度":
				strResult[3] = "2";
				strResult[4] = "中度心理健康问题";
				break;
			case "较重":
				strResult[3] = "3";
				strResult[4] = "较重心理健康问题";
				break;
			case "严重":
				strResult[3] = "4";
				strResult[4] = "严重心理健康问题";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百十一、新生儿20项行为神经评定(Baby20)
	private String[] GetBaby20Report(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i;

			String[][] strNameA = { { "行为能力", "Xw" }, { "被动肌张力", "Bd" }, { "主动肌张力", "Zd" }, { "原始反射", "Ys" },
					{ "一般反应", "Yb" }, { "总分", "Total" } };

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "因子" + "</td><td" + subTitle(0, tWidth) + ">"
						+ "得分" + "</td></tr>";

				for (i = 0; i < strNameA.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + strNameA[i][0] + "</td><td"
							+ subValue(0, tWidth) + ">" + map.get(strNameA[i][1].toLowerCase() + "_o") + "</td></tr>";
				}

				strResult[1] += "</table>";
			}

			strResult[3] = "0";
			strResult[4] = "";

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百十二、超常行为检查表(4-12岁)(Genius1)
	private String[] GetGenius1Report(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i;

			String[][] strNameA = { { "智力", "Zl" }, { "创造力", "Czl" }, { "美术创造力(附加)", "Ms" }, { "音乐创造力(附加)", "Yy" },
					{ "社会活动和领导能力", "Sh" }, { "身体能力", "St" }, { "总分", "Total" } };

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "因子" + "</td><td" + subTitle(0, tWidth) + ">"
						+ "得分" + "</td></tr>";

				for (i = 0; i < strNameA.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + strNameA[i][0] + "</td><td"
							+ subValue(0, tWidth) + ">" + map.get(strNameA[i][1].toLowerCase() + "_o") + "</td></tr>";
				}

				strResult[1] += "</table>";
			}

			// 医生意见
			String strCode = "";
			for (i = 0; i < strNameA.length; i++) {
				strCode += map.get(strNameA[i][1].toLowerCase() + "_d") + "|";
			}

			if (strCode.length() > 0) {
				strCode = strCode.substring(0, strCode.length() - 1);
			}

			strResult[2] = strCode;

			switch (String.valueOf(map.get("total_d")).split("\\.")[2]) {
			case "1":
				strResult[3] = "*";
				strResult[4] = "能力较低";
				break;
			case "2":
				strResult[3] = "0";
				strResult[4] = "能力为中等水平";
				break;
			case "3":
				strResult[3] = "0";
				strResult[4] = "能力较高";
				break;
			case "4":
				strResult[3] = "0";
				strResult[4] = "能力优秀";
				break;
			case "5":
				strResult[3] = "0";
				strResult[4] = "能力极优";
				break;
			case "6":
				strResult[3] = "0";
				strResult[4] = "奇才";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百十三、超常行为检查表(12岁以上)(Genius2)
	private String[] GetGenius2Report(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i;

			String[][] strNameA = { { "智力", "Zl" }, { "创造力", "Czl" }, { "社会活动和领导能力", "Sh" }, { "身体能力", "St" },
					{ "总分", "Total" } };

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "因子" + "</td><td" + subTitle(0, tWidth) + ">"
						+ "得分" + "</td></tr>";

				for (i = 0; i < strNameA.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + strNameA[i][0] + "</td><td"
							+ subValue(0, tWidth) + ">" + map.get(strNameA[i][1].toLowerCase() + "_o") + "</td></tr>";
				}

				strResult[1] += "</table>";
			}

			// 医生意见
			String strCode = "";
			for (i = 0; i < strNameA.length; i++) {
				strCode += map.get(strNameA[i][1].toLowerCase() + "_d") + "|";
			}

			if (strCode.length() > 0) {
				strCode = strCode.substring(0, strCode.length() - 1);
			}

			strResult[2] = strCode;

			switch (String.valueOf(map.get("total_d")).split("\\.")[2]) {
			case "1":
				strResult[3] = "*";
				strResult[4] = "能力较低";
				break;
			case "2":
				strResult[3] = "0";
				strResult[4] = "能力为中等水平";
				break;
			case "3":
				strResult[3] = "0";
				strResult[4] = "能力较高";
				break;
			case "4":
				strResult[3] = "0";
				strResult[4] = "能力优秀";
				break;
			case "5":
				strResult[3] = "0";
				strResult[4] = "能力极优";
				break;
			case "6":
				strResult[3] = "0";
				strResult[4] = "奇才";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百十四、威廉斯创造力倾向测验(Create)
	private String[] GetCreateReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i;

			String[] strCodeA = { "I", "II", "III", "IV", "V" };
			String[][] strNameA = { { "冒险性", "Mx" }, { "好奇性", "Hq" }, { "想象力", "Xx" }, { "挑战性", "Tz" },
					{ "总分", "Total" } };

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "" + "</td><td" + subTitle(0, tWidth) + ">"
						+ "因子" + "</td><td" + subTitle(0, tWidth) + ">" + "得分" + "</td></tr>";

				for (i = 0; i < strNameA.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + strCodeA[i] + "</td><td"
							+ subTitle(0, tWidth) + ">" + strNameA[i][0] + "</td><td" + subValue(0, tWidth) + ">"
							+ map.get(strNameA[i][1].toLowerCase() + "_o") + "</td></tr>";
				}

				strResult[1] += "</table>";
			}

			// 医生意见
			String strCode = "";
			for (i = 0; i < strNameA.length; i++) {
				strCode += map.get(strNameA[i][1].toLowerCase() + "_d") + "|";
			}

			if (strCode.length() > 0) {
				strCode = strCode.substring(0, strCode.length() - 1);
			}

			strResult[2] = strCode;

			switch (String.valueOf(map.get("total_d")).split("\\.")[2]) {
			case "1":
			case "2":
				strResult[3] = "*";
				strResult[4] = "异常";
				break;
			default:
				strResult[3] = "0";
				strResult[4] = "正常";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百十五、中学生学习方法测验(Xxff)
	private String[] GetXxffReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "总分" + "</td><td" + subValue(0, -1) + ">"
						+ map.get("total_o") + "</td></tr>";

				strResult[1] += "</table>";
			}

			// 医生意见
			strResult[2] = String.valueOf(map.get("total_d"));

			strResult[3] = "0";
			strResult[4] = "";

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百十六、中学生学习动机调查表(Xxdj)
	private String[] GetXxdjReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i;

			String[][] strNameA = { { "学习动机", "Dj" }, { "学习压力", "Yl" }, { "学习兴趣", "Xq" }, { "学习目标", "Mb" } };

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "因子" + "</td><td" + subTitle(0, tWidth) + ">"
						+ "得分" + "</td><td" + subTitle(0, tWidth) + ">" + "参考诊断" + "</td></tr>";

				for (i = 0; i < strNameA.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + strNameA[i][0] + "</td><td"
							+ subValue(0, tWidth) + ">" + map.get(strNameA[i][1].toLowerCase() + "_o") + "</td><td"
							+ subValue(0, tWidth) + ">" + map.get(strNameA[i][1].toLowerCase() + "_a") + "</td></tr>";
				}

				strResult[1] += "</table>";
			}

			// 预警
			if (String.valueOf(map.get("dj_a")).equals("很弱")) {
				strResult[3] = "*";
				strResult[4] += "学习动机" + "很弱" + "，";
			}
			if (String.valueOf(map.get("yl_a")).equals("很大")) {
				strResult[3] = "*";
				strResult[4] += "学习压力" + "很大" + "，";
			}
			if (String.valueOf(map.get("xq_a")).equals("有很大困扰")) {
				strResult[3] = "*";
				strResult[4] += "学习兴趣" + "有很大困扰" + "，";
			}
			if (String.valueOf(map.get("mb_a")).equals("不太合理")) {
				strResult[3] = "*";
				strResult[4] += "学习目标" + "不太合理" + "，";
			}

			if (strResult[4].length() > 0) {
				strResult[4] = strResult[4].substring(0, strResult[4].length() - 1);
			} else {
				strResult[3] = "0";
				strResult[4] = "";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百十七、中学生意志力调查表(Yzldc)
	private String[] GetYzldcReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "总分" + "</td><td" + subValue(0, -1) + ">"
						+ map.get("total_o") + "</td></tr>";

				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			switch (String.valueOf(map.get("total_d")).split("\\.")[2]) {
			case "1":
				strResult[3] = "*";
				strResult[4] = "意志很薄弱";
				break;
			case "2":
				strResult[3] = "*";
				strResult[4] = "意志较薄弱";
			case "3":
				strResult[3] = "*";
				strResult[4] = "意志品质一般";
			case "4":
				strResult[3] = "*";
				strResult[4] = "意志较坚强";
			case "5":
				strResult[3] = "*";
				strResult[4] = "意志很坚强";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百十八、考试行为困扰心理测查(Ksxwkl)
	private String[] GetKsxwklReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i;

			String[][] strNameA = { { "动机与效果", "Dj" }, { "应试技巧", "Ss" }, { "考前身心健康", "Kq" }, { "心理控制能力", "Xl" } };

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "因子" + "</td><td" + subTitle(0, tWidth) + ">"
						+ "得分" + "</td><td" + subTitle(0, tWidth) + ">" + "参考范围" + "</td></tr>";

				for (i = 0; i < strNameA.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + strNameA[i][0] + "</td><td"
							+ subValue(0, tWidth) + ">" + map.get(strNameA[i][1].toLowerCase() + "_o") + "</td><td"
							+ subValue(0, tWidth) + ">" + "（0 - 20分）" + "</td></tr>";
				}

				strResult[1] += "</table>";
			}

			// 医生意见
			String strCode = "";
			for (i = 0; i < strNameA.length; i++) {
				strCode += map.get(strNameA[i][1].toLowerCase() + "_d") + "|";
			}

			if (strCode.length() > 0) {
				strCode = strCode.substring(0, strCode.length() - 1);
			}
			strResult[2] = strCode;

			strResult[3] = "0";
			strResult[4] = "";

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百十九、中学生自信心困扰检测(Zbxl)
	private String[] GetZbxlReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "总分" + "</td><td" + subValue(0, -1) + ">"
						+ map.get("total_o") + "</td></tr>";

				strResult[1] += "</table>";
			}

			// 医生意见
			strResult[2] = String.valueOf(map.get("total_d"));

			switch (String.valueOf(map.get("total_a"))) {
			case "环境变化影响自信":
				strResult[3] = "*";
				strResult[4] = "环境变化影响自信";
				break;
			case "动机与期望过高而影响自信":
				strResult[3] = "*";
				strResult[4] = "动机与期望过高而影响自信";
				break;
			case "过早断定影响自信":
				strResult[3] = "*";
				strResult[4] = "过早断定影响自信";
				break;
			case "性格怯懦影响自信":
				strResult[3] = "*";
				strResult[4] = "性格怯懦影响自信";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百二十、中学生在校适应能力诊断(Zxsynl)
	private String[] GetZxsynlReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "总分" + "</td><td" + subValue(0, -1) + ">"
						+ map.get("total_o") + "</td></tr>";

				strResult[1] += "</table>";
			}

			// 医生意见
			strResult[2] = String.valueOf(map.get("total_d"));

			switch (String.valueOf(map.get("total_d")).split("\\.")[2]) {
			case "1":
				strResult[3] = "0";
				strResult[4] = "社会适应能力很强";
				break;
			case "2":
				strResult[3] = "0";
				strResult[4] = "社会适应能力良好";
				break;
			case "3":
				strResult[3] = "0";
				strResult[4] = "社会适应能力一般";
				break;
			case "4":
				strResult[3] = "1";
				strResult[4] = "社会适应能力较差";
				break;
			case "5":
				strResult[3] = "2";
				strResult[4] = "社会适应能力很差";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百二十一、学生人际交往能力自我评定(Rjjwnl)
	private String[] GetRjjwnlReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i;

			String[][] strNameA = { { "总分", "Total" }, { "同学关系", "Tx" }, { "家庭关系", "Jt" }, { "师生关系", "Ss" } };

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "因子" + "</td><td" + subTitle(0, tWidth) + ">"
						+ "得分" + "</td><td" + subTitle(0, -1) + ">" + "参考诊断" + "</td></tr>";

				for (i = 0; i < strNameA.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + strNameA[i][0] + "</td><td"
							+ subValue(0, tWidth) + ">" + map.get(strNameA[i][1].toLowerCase() + "_o") + "</td><td"
							+ subValue(0, -1) + ">" + map.get(strNameA[i][1].toLowerCase() + "_a") + "</td></tr>";
				}

				strResult[1] += "</table>";
			}

			switch (String.valueOf(map.get("total_a"))) {
			case "交往能力弱，人际关系一般。":
				strResult[3] = "*";
				strResult[4] += "交往能力弱，人际关系一般" + "，";
				break;
			case "交往能力一般。":
				strResult[3] = "0";
				strResult[4] += "交往能力一般" + "，";
				break;
			case "交往能力强，人际关系好。":
				strResult[3] = "0";
				strResult[4] += "交往能力强，人际关系好" + "，";
				break;
			}

			for (i = 0; i < strNameA.length; i++) {
				if (String.valueOf(map.get(strNameA[i][1].toLowerCase() + "_a")).equals("关系较差。")) {
					strResult[3] = "*";
					strResult[4] += strNameA[i][0].toString() + "较差" + "，";
				}
			}

			if (strResult[4].length() > 0) {
				strResult[4] = strResult[4].substring(0, strResult[4].length() - 1);
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百二十二、同学关系困扰调查表(Txgxkr)
	private String[] GetTxgxkrReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i;

			String[][] strNameA = { { "总分", "Total" }, { "言语沟通", "Yygt" }, { "交往行为", "Jwxw" }, { "待人接物", "Drjw" },
					{ "异性交往", "Yxjw" } };

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "因子" + "</td><td" + subTitle(0, tWidth) + ">"
						+ "得分" + "</td><td" + subTitle(0, -1) + ">" + "参考诊断" + "</td></tr>";

				for (i = 0; i < strNameA.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + strNameA[i][0] + "</td><td"
							+ subValue(0, tWidth) + ">" + map.get(strNameA[i][1].toLowerCase() + "_o") + "</td><td"
							+ subValue(0, -1) + ">" + map.get(strNameA[i][1].toLowerCase() + "_a") + "</td></tr>";
				}

				strResult[1] += "</table>";
			}

			switch (String.valueOf(map.get("total_a"))) {
			case "说明你与朋友相处的困扰较少。":
				strResult[3] = "0";
				strResult[4] = "困扰较少";
				break;
			case "说明你与朋友相处存在一定程度的困扰。":
				strResult[3] = "1";
				strResult[4] = "存在一定程度的困扰";
				break;
			case "说明你与朋友相处的行为困扰较严重。":
				strResult[3] = "2";
				strResult[4] = "行为困扰较严重";
				break;
			case "说明你与朋友相处存在严重的行为困扰。":
				strResult[3] = "3";
				strResult[4] = "存在严重的行为困扰";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百二十三、师生关系困扰调查表(Ssgxkr)
	private String[] GetSsgxkrReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i;

			String[][] strNameA = { { "总分", "Total" }, { "教学过程", "Jxgc" }, { "情感距离", "Qgjl" }, { "地位关系", "Dwgx" } };

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "因子" + "</td><td" + subTitle(0, tWidth) + ">"
						+ "得分" + "</td><td" + subTitle(0, -1) + ">" + "参考诊断" + "</td></tr>";

				for (i = 0; i < strNameA.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + strNameA[i][0] + "</td><td"
							+ subValue(0, tWidth) + ">" + map.get(strNameA[i][1].toLowerCase() + "_o") + "</td><td"
							+ subValue(0, -1) + ">" + map.get(strNameA[i][1].toLowerCase() + "_a") + "</td></tr>";
				}

				strResult[1] += "</table>";
			}

			switch (String.valueOf(map.get("total_a"))) {
			case "困扰程度较轻或很轻微。":
				strResult[3] = "0";
				strResult[4] = "困扰程度较轻或很轻微";
				break;
			case "困扰程度中度。":
				strResult[3] = "1";
				strResult[4] = "困扰程度中度";
				break;
			case "困扰程度严重或比较严重。":
				strResult[3] = "2";
				strResult[4] = "困扰程度严重或比较严重";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百二十四、一般自我效能感测验(中学)(Ybzwxng)
	private String[] GetYbzwxngReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "总分" + "</td><td" + subValue(0, -1) + ">"
						+ map.get("total_o") + "</td></tr>";
				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "平均分" + "</td><td" + subValue(0, -1) + ">"
						+ map.get("total_ave") + "</td></tr>";

				strResult[1] += "</table>";
			}

			// 医生意见
			strResult[2] = String.valueOf(map.get("total_d"));

			strResult[3] = "0";
			strResult[4] = "";

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百二十五、一般性焦虑问卷(Gat)
	private String[] GetGatReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i;

			String[][] strNameA = { { "总分", "Total" }, { "学习不安", "Xx" }, { "对人不安", "Dr" }, { "孤独倾向", "Gd" },
					{ "自责倾向", "Zz" }, { "过敏倾向", "Gm" }, { "身体征候", "St" }, { "恐惧倾向", "Kj" }, { "冲动倾向", "Cd" },
					{ "信度", "Xd" } };

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "因子" + "</td><td" + subTitle(0, tWidth) + ">"
						+ "得分" + "</td><td" + subTitle(0, -1) + ">" + "参考诊断" + "</td></tr>";

				for (i = 0; i < strNameA.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + strNameA[i][0] + "</td><td"
							+ subValue(0, tWidth) + ">" + map.get(strNameA[i][1].toLowerCase() + "_o") + "</td><td"
							+ subValue(0, -1) + ">" + map.get(strNameA[i][1].toLowerCase() + "_a") + "</td></tr>";
				}

				strResult[1] += "</table>";
			}

			if (String.valueOf(map.get("total_a")).equals("正常。")) {
				strResult[3] = "0";
				strResult[4] = "正常";
			} else {
				strResult[3] = "*";
				strResult[4] = "异常";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百二十六、小学生心理健康综合测量(Xxxljkzh)
	// ---table_uuid: 98C5350E-13B2-43EC-AA36-794312D47D4E
	private String[] GetXxxljkzhReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i;

			String[][] strNameA = { { "学习障碍", "Xx" }, { "情绪障碍", "Qx" }, { "性格缺陷", "Xg" }, { "社会适应障碍", "Sh" },
					{ "品德缺陷", "Pd" }, { "不良习惯", "Bl" }, { "行为障碍", "Xw" }, { "特种障碍", "Tz" } };

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "因子" + "</td><td" + subTitle(0, tWidth) + ">"
						+ "得分" + "</td><td" + subTitle(0, -1) + ">" + "参考诊断" + "</td></tr>";

				for (i = 0; i < strNameA.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + strNameA[i][0] + "</td><td"
							+ subValue(0, tWidth) + ">" + map.get(strNameA[i][1].toLowerCase() + "_o") + "</td><td"
							+ subValue(0, -1) + ">" + map.get(strNameA[i][1].toLowerCase() + "_a") + "</td></tr>";
				}

				strResult[1] += "</table>";
			}

			for (i = 0; i < strNameA.length; i++) {
				switch (String.valueOf(map.get(strNameA[i][1].toLowerCase() + "_a"))) {
				case "异常，需要接受心理辅导。":
					strResult[3] = "*";
					strResult[4] += strNameA[i][0].toString() + "异常" + "，";
					break;
				case "可能异常，需要引起关注。":
					strResult[3] = "0";
					strResult[4] += strNameA[i][0].toString() + "可能异常" + "，";
					break;
				}
			}

			if (strResult[3].equals("")) {
				strResult[3] = "0";
				strResult[4] = "正常";
			} else {
				if (strResult[4].length() > 0) {
					strResult[4] = strResult[4].substring(0, strResult[4].length() - 1);
				}
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百二十七、中学生心理健康综合测量(Zxxljkzh)
	private String[] GetZxxljkzhReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i;

			String[][] strNameA = { { "总分", "Total" }, { "学习焦虑", "Xx" }, { "对人焦虑", "Dr" }, { "孤独倾向", "Gd" },
					{ "自责倾向", "Zz" }, { "过敏倾向", "Gm" }, { "身体症状", "St" }, { "恐怖倾向", "Kb" }, { "冲动倾向", "Cd" },
					{ "掩饰分", "Ys" } };

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "因子" + "</td><td" + subTitle(0, -1) + ">" + "得分"
						+ "</td></tr>";

				for (i = 0; i < strNameA.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + strNameA[i][0] + "</td><td"
							+ subValue(0, -1) + ">" + map.get(strNameA[i][1].toLowerCase() + "_o") + "</td></tr>";
				}

				strResult[1] += "</table>";
			}

			// 医生意见
			// 这个量表比较特殊，最后一个“掩饰分”是没有指导意见的，所以循环时减一
			String strCode = "";
			for (i = 0; i < strNameA.length - 1; i++) // 不包括“掩饰分”
			{
				strCode += map.get(strNameA[i][1].toLowerCase() + "_d") + "|";
			}

			if (strCode.length() > 0) {
				strCode = strCode.substring(0, strCode.length() - 1);
			}

			strResult[2] = strCode;

			switch (String.valueOf(map.get("total_d")).split("\\.")[2]) {
			case "1":
				strResult[3] = "2";
				strResult[4] = "存在一定的心理障碍";
				break;
			case "2":
				strResult[3] = "1";
				strResult[4] = "可能存在心理问题";
				break;
			case "3":
				strResult[3] = "0";
				strResult[4] = "心理基本健康";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百二十八、R.C检测表Rc
	private String[] GetRcReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i;

			String[][] strNameA = { { "法制观念", "Fzgn" }, { "道德水平", "Ddsp" }, { "心理健康状况", "Xljk" }, { "就业能力", "Jynl" },
					{ "文化素质", "Whsz" } };

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "因子" + "</td><td" + subTitle(0, -1) + ">"
						+ "原始分" + "</td></tr>";

				for (i = 0; i < strNameA.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + strNameA[i][0] + "</td><td"
							+ subValue(0, -1) + ">" + map.get(strNameA[i][1].toLowerCase() + "_o") + "</td></tr>";
				}

				strResult[1] += "</table>";
			}

			// 医生意见
			String strCode = "";
			for (i = 0; i < strNameA.length; i++) {
				strCode += map.get(strNameA[i][1].toLowerCase() + "_d") + "|";
			}

			if (strCode.length() > 0) {
				strCode = strCode.substring(0, strCode.length() - 1);
			}

			strResult[2] = strCode;

			for (i = 0; i < strNameA.length; i++) {
				if (String.valueOf(map.get(strNameA[i][1].toLowerCase() + "_d")).split("\\.")[2].equals("3")) {
					strResult[3] = "*";
					strResult[4] += strNameA[i][0].toString() + "异常" + "，";
				}
			}

			if (strResult[4].length() > 0) {
				strResult[4] = strResult[4].substring(0, strResult[4].length() - 1);
			} else {
				strResult[3] = "0";
				strResult[4] += "正常";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百二十九、创伤事件影响评定量表Trauma
	private String[] GetTraumaReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "总分" + "</td><td" + subValue(0, -1) + ">"
						+ map.get("total_o") + "</td></tr>";
				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "参考诊断" + "</td><td" + subValue(0, -1) + ">"
						+ map.get("total_a") + "</td></tr>";

				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			switch (String.valueOf(map.get("total_a"))) {
			case "正常":
				strResult[3] = "0";
				strResult[4] = "正常";
				break;
			case "轻度":
				strResult[3] = "1";
				strResult[4] = "症状较轻";
				break;
			case "中度":
				strResult[3] = "2";
				strResult[4] = "症状明显";
				break;
			case "重度":
				strResult[3] = "3";
				strResult[4] = "症状较重";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百三十、公安民警危机意念自评量表Shcrisis
	private String[] GetShcrisisReport(Map<String, Object> map) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			int i;

			// 得分12分作为初步筛选有自杀意念者的划界点。
			// 得分越高, 自杀意念越强
			// 超过4分，则提示测量不可靠，有一定借鉴意义。

			String[][] strNameA = { { "绝望因子", "Despair" }, { "乐观因子", "Optimism" }, { "睡眠因子", "Sleep" },
					{ "掩饰因子", "Conceal" }, { "自杀意念", "Suicide" }, { "总分", "Total" } };
			String[] dis = { "", "", "", "超过4分，则提示测量不可靠，有一定借鉴意义。", "得分越高, 自杀意念越强", "得分12分作为初步筛选有自杀意念者的划界点。" };

			if (g_inblFactor) // 因子得分
			{
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";

				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "因子" + "</td><td" + subTitle(0, tWidth) + ">"
						+ "得分" + "</td><td" + subTitle(0, -1) + ">" + "参考内容" + "</td></tr>";

				for (i = 0; i < strNameA.length; i++) {
					strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + strNameA[i][0] + "</td><td"
							+ subValue(0, tWidth) + ">" + map.get(strNameA[i][1].toLowerCase() + "_o") + "</td><td"
							+ subValue(0, -1) + ">" + dis[i] + "</td></tr>";
				}

				strResult[1] += "</table>";
			}

			// 医生意见
			String[] strDot = { "Total", "Suicide", "Conceal" };
			String strCode = "";
			for (i = 0; i < strDot.length; i++) {
				strCode += map.get(strDot[i].toLowerCase() + "_d") + "|";
			}

			if (strCode.length() > 0) {
				strCode = strCode.substring(0, strCode.length() - 1);
			}

			strResult[2] = strCode;

			// 预警，总分超过12分提示异常
			if (Float.valueOf(String.valueOf(map.get("total_o"))) > 12f) {
				strResult[3] = "*";
				strResult[4] = "异常";
			} else {
				strResult[3] = "0";
				strResult[4] = "正常";
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

	// 一百三十一、公安民警应激生活事件调查表Shirritant，量表特殊，需要传入原始题目的选项
	private String[] GetShirritantReport(Map<String, Object> map, String vAnswerString) {
		// 下面因子名称字段改成.toLowerCase()小写，是因为JAVA转json的时候会把大写字母转成小写字母
		// 第一个，错误信息；第二个，量表得分部分；第三个，量表指导意见_d数组部分
		// String[] strResult = {"","",""};
		String[] strResult = { "", "", "", "", "" };
		try {
			if (g_inblFactor) {
				strResult[1] += "<table cellpadding='0' cellspacing='0' width='100%' border='0'>";
				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "总分" + "</td><td" + subValue(0, -1) + ">"
						+ map.get("total_o") + "</td></tr>";
				// String[] answer = vAnswerString.split("@@");
				// ******************************************************************************
				int intI;
				// 转换回原来格式
				String strTemp = vAnswerString.replaceAll("\\|@", "\\|0@@");
				// 临时赋值，JAVA默认切割时为空就不增加数组长度
				String[] strAnswer_c_Temp = strTemp.split("@@");
				String[] answer = { "", "" };
				for (intI = 0; intI < strAnswer_c_Temp.length; intI++) {
					answer[intI] = strAnswer_c_Temp[intI].trim();
				}
				// ******************************************************************************

				String ans28 = "";
				if (answer.length > 1) {
					ans28 = answer[1];
				}
				strResult[1] += "<tr><td" + subTitle(0, tWidth) + ">" + "第28题" + "</td><td" + subValue(0, -1) + ">"
						+ ans28 + "</td></tr>";
				strResult[1] += "</table>";
			}

			strResult[2] = String.valueOf(map.get("total_d"));

			switch (String.valueOf(map.get("total_d")).split("\\.")[2]) {
			case "1":
				strResult[3] = "0";
				strResult[4] = "正常";
				break;
			case "2":
				strResult[3] = "1";
				strResult[4] = "需要简单辅导";
				break;
			case "3":
				strResult[3] = "2";
				strResult[4] = "需要开展心理危机干预";
				break;
			}

			return strResult;
		} catch (ArithmeticException e) {
			strResult[0] = "失败";
			return strResult;
		}
	}

}
